How to Make a Call Which Begin with * in Iphone

Call to a number, which contain #. (IPhone SDK)

iOS SDK (Apple URL scheme reference) tells:
To prevent users from maliciously redirecting phone calls or changing the behavior of a phone or account, the Phone application supports most, but not all, of the special characters in the tel scheme. Specifically, if a URL contains the * or # characters, the Phone application does not attempt to dial the corresponding phone number.

So, no luck.

Making calls on iPhone/iPod/iPad

Every iOS 8 device has the FaceTime App which now provides the power to call anyone your iPhone can call.

It's called continuity

The user has to allow this on his iPhone in Settings.app under "FaceTime" -> "iPhone Cellular Calls"

How to make a call programmatically?

Keep the phone number in a separate string.

NSString *phoneNumber = @"1-800-555-1212"; // dynamically assigned
NSString *phoneURLString = [NSString stringWithFormat:@"tel:%@", phoneNumber];
NSURL *phoneURL = [NSURL URLWithString:phoneURLString];
[[UIApplication sharedApplication] openURL:phoneURL];


Related Topics



Leave a reply



Submit