Re: File Path -> FSSpec?
Re: File Path -> FSSpec?
- Subject: Re: File Path -> FSSpec?
- From: Johnny CN Lee <email@hidden>
- Date: Fri, 26 Oct 2001 11:13:46 +0800
on 10/26/01 11:05 AM, Brendan Younger at email@hidden wrote:
>
Try Carbon's FSMakeFSSpec(). It will accept full pathnames.
Yes. But FSMakeFSSpec doesn't recognize UNIX file path
("/path/filename.ext").
Anyway, I've found a way to do it: Use NSFileManager's
fileAttributesAtPath:traverseLink:, then use NSFileDeviceIdentifier as
vRefNum, and fileSystemFileNumber as dirID, and pass an empty string to
FSMakeFSSpec to create the FSSpec structure.
Thanks,
J Lee