Hello,
I'm fetching data from a sqlite database in my iPhone program. What I get from the DB is then placed in a UITextView
. An example of text that is fetched is:
"Hello this is a example. It has "" double quotes "" and ends with simple"
I want to eliminate the single one, and replace the double by singles. But It's not working. Here is my code:
NSString *question;
question = [[NSString stringWithUTF8String:(char *)sqlite3_column_text(statement1,1)] copy];
question = [question stringByReplacingOccurrencesOfString:@"\"\"" withString:@"$$"];
question = [question stringByReplacingOccurrencesOfString:@"\"" withString:@""];
question = [question stringByReplacingOccurrencesOfString:@"$$" withString:@"\""];
What is wrong?
Thanks very much!