• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: File Path -> FSSpec?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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


  • Follow-Ups:
    • Re: File Path -> FSSpec?
      • From: Eric Schlegel <email@hidden>
References: 
 >Re: File Path -> FSSpec? (From: Brendan Younger <email@hidden>)

  • Prev by Date: Re: Drawing a String in Java
  • Next by Date: Re: Drawing a String in Java
  • Previous by thread: Re: File Path -> FSSpec?
  • Next by thread: Re: File Path -> FSSpec?
  • Index(es):
    • Date
    • Thread