KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
Let's assume I have the string NSString* myString = @"Hello,"; How can I remove the comma without leaving a space? I have tried: NSString* newString = [myString stringByReplacingOccurrencesOfString:@"," withString:@""]; and NSString* newString = [myString stringByTrimmingCharactersInSet:[NSCharacterSet punctuationCharacterSet]]; But both are leaving spaces.
Tags (comma-separated)
Save Edits
Cancel