Tuesday, May 31, 2011

How can I know if my iOS device supports phone calls?

The easiest way is to check if the tel:// protocol is supported on the device

[[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"tel://"]];

canOpenURL: explicitly checks whether there's an application capable of opening that URL scheme, not that the URL is correct.

No comments: