Can any one tell me how to format MSISDN number in xcode IPhone application. I have MSISDN number as “(911-111-1111)”. I need to remove the bracket and “-” between numbers. How can i achieve this.
Thanks
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
There are many ways to do this (almost all of which can be found by quick examination of the NSString and NSMutableString class references).
If all you want to do is strip characters, I would probably do something like
This isn’t the most efficient (or necessarily “elegant”) way to do it, but it has the advantage of being the most readable.