• 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: Saving UTF-8 as File
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Saving UTF-8 as File


  • Subject: Re: Saving UTF-8 as File
  • From: Douglas Davidson <email@hidden>
  • Date: Tue, 19 Apr 2005 11:26:54 -0700


On Apr 19, 2005, at 10:53 AM, August Trometer wrote:

However, when I save to a file (using NSString writeToFile:atomically), it doesn't save as UTF-8 and when the file is read I get all kinds of bogus characters.



Get the dataUsingEncoding:NSUTF8StringEncoding and write that to the file.  After the 29th, there will be something else you can do--look through NSString.h.  The point is that you have to specify the encoding to be able to write it out properly.

Douglas Davidson

 _______________________________________________
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: 
 >Saving UTF-8 as File (From: August Trometer <email@hidden>)

  • Prev by Date: Re: Saving UTF-8 as File
  • Next by Date: Re: upper limit on retain count
  • Previous by thread: Re: Saving UTF-8 as File
  • Next by thread: Re: Saving UTF-8 as File
  • Index(es):
    • Date
    • Thread