I\'ve been trying to get rid of the white spaces in an NSString, but none of the methods I\'ve tried worked.
I have \"this is a test\" and
This may help you if you are experiencing \u00a0 in stead of (whitespace). I had this problem when I was trying to extract Device Contact Phone Numbers. I needed to modify the phoneNumber string so it has no whitespace in it.
NSString* yourString = [yourString stringByReplacingOccurrencesOfString:@"\u00a0" withString:@""];
When yourString was the current phone number.