• 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: NSData writeToFile:atomically not working right??
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSData writeToFile:atomically not working right??


  • Subject: Re: NSData writeToFile:atomically not working right??
  • From: email@hidden
  • Date: Tue, 9 Aug 2005 14:52:53 -0400

On Aug 9, 2005, at 2:41 PM, Scott Mitchell wrote:

When I call this isWritten comes back as YES (meaning the file was written but when I go and look at the path of where it is to be written, the file is not there????

isWritten = NO;
outFile = [outFile stringByExpandingTildeInPath];
[outFile retain];
isWritten = [outData writeToFile:outFile atomically:YES];
[outFile release];

It's probably a problem with your path (or the way it's in the code); you might want to try using something like:


outFile = [outFile stringByStandardizingPath];

Ohter than that, I would try experimenting with different, perhaps more simple paths. For example, using "~/outfile.data" should write a file called "outfile.data" to the user's home directory.

Cameron
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >NSData writeToFile:atomically not working right?? (From: Scott Mitchell <email@hidden>)

  • Prev by Date: Re: NsColorWell Connection Issue
  • Next by Date: Helpbooks
  • Previous by thread: NSData writeToFile:atomically not working right??
  • Next by thread: Re: NSData writeToFile:atomically not working right??
  • Index(es):
    • Date
    • Thread