iphone - Core data and special characters (UTF-8) -


I have an iPhone application that uses core data with the SQL database in the data below. Writing content to a file, but in special characters like A, A and O files are corrupt (they appear just fine in the application).

To insert data, I'm not using any special encoding. I'm just taking NSString (entered by UITFfield by the user) and putting it in my constant items while saving the file, I use the following code:

  [csvString writeToFile : Filepath atomically: Yes Encoding: NSUTF8StringEncoding Error: & amp; Error]; I tried to add a BOM ("\ xef \ xbb \ xbf") at the beginning of the text but it is still corrupt. Any person has an idea where the problem can be? 

Examples of contaminated characters: one becomes,

Your example is Correct Correct UTF-8 characters are considered as ISO-8859-1. How are you viewing the file? Are you certain that the viewer you are using is actually interpreting the file as UTF-8?


Comments

Popular posts from this blog

windows - Heroku throws SQLITE3 Read only exception -

lex - Building a lexical Analyzer in Java -

python - rename keys in a dictionary -