• 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: Embarrassing NSURL problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Embarrassing NSURL problem


  • Subject: Re: Embarrassing NSURL problem
  • From: Glenn Howes <email@hidden>
  • Date: Mon, 7 Oct 2002 21:50:10 -0500

If you can use Carbon calls, can't you cast the NSURL as a CFURL and
convert that to a FSRef and then use the appropriate Resource manager
call:

FSRef theFileRef;
if(CFURLGetFSRef((CFURLRef) yourURL, & theFileRef))
{
short refNum = FSOpenResFile(&theFileRef,fsRdPerm);

...

On Monday, October 7, 2002, at 09:22 PM, Ken Tozier wrote:

> I'm writing a class to read AETE's from the resource fork of
> applications and find that I have no clue how to actually do this in
> Cocoa. In the bad old days, I would simply pass an FSSpec to FSpOpenRF
> and be on my merry way. I tried to figure out how to do this using
> NSURL routines but must admit defeat. I'd like to learn the new way,
> but couldn't find a single example that showed how to actually open a
> file in OS X. Could someone send me a link or provide a snippet on how
> to open resource forks?
>
> Thanks
>
> KT
> _______________________________________________
> 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.

References: 
 >Embarrassing NSURL problem (From: Ken Tozier <email@hidden>)

  • Prev by Date: Re: cocoa-dev digest, Vol 2 #1346 - 16 msgs
  • Next by Date: Re: "greedy" NSOpenGLViews
  • Previous by thread: Embarrassing NSURL problem
  • Next by thread: Tearing down a DO connection
  • Index(es):
    • Date
    • Thread