I need to convert NSString in unicode to NSString in ASCII changing all local characters: Ą to A, Ś to S, Ó to O, ü to u, And so on...
What is the simplest way to do it?
-[NSString dataUsingEncoding:NSASCIIStringEncoding allowLossyConversion:YES]
.
All of the examples you gave are handled as you want. Looks like characters with no obvious analog, such as ☃, go to '?'.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With