Best way to trim white spaces from a NSString

Do you guys stuck with trimming white-spaces ? Following snip of code would surely help you to trim string.

As you can notice that, strUserName string will have trimmed characters from textField of UserName. Examples

Also the create … Continue reading