Re: Creating alias programatically
Re: Creating alias programatically
- Subject: Re: Creating alias programatically
- From: Nick Zitzmann <email@hidden>
- Date: Tue, 23 Sep 2008 14:52:20 -0600
On Sep 23, 2008, at 2:48 PM, chaitanya pandit wrote:
I tried using:
OSErr FSNewAliasFromPath ( const char *fromFilePath, const char
*targetPath, OptionBits flags, AliasHandle *inAlias, Boolean
*isDirectory );
But i don't quite get how should i use the fromFilePath parameter,
say i want to create an alias for "Users/me/Documents/foo" at "Users/
me/Desktop/foo"
should i pass the first path as "fromFilePath"?
Yes. If you have the paths as NSStrings, then use -
fileSystemRepresentation (not -UTF8String and definitely not -
cStringUsingEncoding:) to get a path string.
Nick Zitzmann
<http://www.chronosnet.com/>
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please 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