[Solved] Replace occurrences of NSString with `’` to `\’`

[ad_1]

Note: \ is escape character in objective c.

 NSString *s = @"This is Testing Mode and we are testing just Details of this Ladies' Market place";


NSString *r = [s stringByReplacingOccurrencesOfString:@"'" withString:@"\\'"];

0

[ad_2]

solved Replace occurrences of NSString with `’` to `\’`