code for how to perform calling and cancel the calling in iphone
I am new to developing iPhone applications.
I am looking for an example on calling phone numbers, specifically starting a call and ending one.
Is this possible ? If so, how would one accomp开发者_开发技巧lish this ?
Here is the code to make a call
[[UIApplication sharedApplication] openURL:[NSURL URLWithString: @"tel:1-800-ACCE-PTME"]];
Anything that modifies a user's ability to block phone calls is going to run afoul of Apple's basic approach to third-party apps. There are a lot of things that are questionable and you might get away with. Blocking calls is clearly forbidden.
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tel:374347347"]];
I don't think Apple allows you to cancel calls from within your app.
精彩评论