Re: filePath issue?
Re: filePath issue?
- Subject: Re: filePath issue?
- From: "Julien Jalon" <email@hidden>
- Date: Sat, 10 Feb 2007 03:10:15 +0100
You should always use absolute paths.
In general, you get your resources file path using -[NSBundle
pathToResourceXXX] APIs.
There is a special convenient way for images inside your application
Resources folder: -[NSImage imageNamed:]
--
Julien
On 2/9/07, CoreX2 <email@hidden> wrote:
hello everyone, there is a problem about the file path.
I want to generate a NSImage instance with the method:
- initByReferencingFile:(NSString *) filename;
If I want to use the relative path, for example : I add a .png file
to my project, then How should I use the png file: juse use the
relative path or the absolute path?
It seems that the absolute path is not the adoptable method to solve
the problem. But if to use the relative path, what path should I
refer: the path linking to my project?
Thanks for any help .
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden