Re: FSRef -> NSString
Re: FSRef -> NSString
- Subject: Re: FSRef -> NSString
- From: Clark Mueller <email@hidden>
- Date: Thu, 16 Jan 2003 16:48:02 -0700
This does what I'm looking for.
Thanks!
Clark
On Thursday, January 16, 2003, at 01:21 AM, email@hidden wrote:
On jeudi, janvier 16, 2003, at 07:18 AM, Clark Mueller wrote:
Is there a way to convert from an FSRef structure to an NSString?
Yes,
convert the FSRef to a CFURLRef , cast the CFURLRef to a NSURL (this
part is optional) and use the NSURL method to get he Posix path name
in a NSString.
NSString * myString;
CFURLRef myURLRef;
myURLRef =CFURLCreateFromFSRef(kCFAllocatorDefault, &myFSRef);
if (myURLRef!=NULL)
{
myString =[(NSURL *) myURLRef path];
}
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.