Reputation: 49067
When I try to dial a telephone number(using openURL method of UIApplication class) with e.g. +47 00 00 00 00 it does not work, however when I change to +4700000000 it works.
I don't need an example of how to convert from the first example to the last, but is there any methods that does this conversion?
Thanks in advance.
Upvotes: 1
Views: 531
Reputation: 7103
Try this:
NSString *withSpaces = @"+47 00 00 00 00"; NSString *withoutSpaces = [withSpaces stringByReplacingOccurrencesOfString:@" " withString:@""];
Upvotes: 3