• 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 to NSString encoding error
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSData to NSString encoding error


  • Subject: Re: NSData to NSString encoding error
  • From: Johan Augustsson <email@hidden>
  • Date: Mon, 10 Jul 2006 14:06:54 -0500

Hi!

Thank you for your answers!
Wow, The problem was very simple. After getting the string I put the value in an NSMutableDictionary, then printed the description of the dictionary NSLog([myDict description]). When you asked me how i generated the description I started to experiment with this.
For some reason [myDict description] doesn't give me same result as NSLog([myDict objectForKey:@"myKey"]), but that won't be a problem for me.


Sorry for the inconvenience.





10 jul 2006 kl. 12.43 skrev j o a r:


On 10 jul 2006, at 18.46, Johan Augustsson wrote:

Description of NSData: "424ad652" The problem is the third byte D6 witch according to latin1 spec should be "Ö"

How do you generate this NSData? Are you certain that it's a representation of a string in Latin1 encoding? It sounds like you are, I'm just double-checking.


Description of my created string: "BJ\U00d6R"

How do you generate this description?

j o a r




_______________________________________________ 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
  • Follow-Ups:
    • Re: Re: NSData to NSString encoding error
      • From: "Shawn Erickson" <email@hidden>
References: 
 >NSData to NSString encoding error (From: Johan Augustsson <email@hidden>)
 >Re: NSData to NSString encoding error (From: j o a r <email@hidden>)

  • Prev by Date: Re: NSWindows/NSPanels/NSDrawers are NIL
  • Next by Date: Re: NSWindows/NSPanels/NSDrawers are NIL
  • Previous by thread: Re: NSData to NSString encoding error
  • Next by thread: Re: Re: NSData to NSString encoding error
  • Index(es):
    • Date
    • Thread