Search code examples
iphonecore-telephony

In iphone how to check that a call is success or not in xcode?


i have to check that whether a call made on a number by code is success or not ,if not then i have to make another call on another number.....

-(IBAction)callPhone:(id)sender {
    [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tel:2135554321"]];
}

Solution

  • You cannot. Apple does not provide you any information about calls at all. You won't know whether the phone actually tried making the call (other than openURL: might return NO if the URL was invalid or some other error occurred).

    This is by design and intended to protect the users' privacy.