0

After my app make a call i would like to return to my app. When user hit "End" in call screen now he always see phone app. How to force app to return to my original app?

I make a call using:

NSString *phoneURLString = [NSString stringWithFormat:@"tel:%@", phoneNumber];
NSURL *phoneURL = [NSURL URLWithString:phoneURLString];
[[UIApplication sharedApplication] openURL:phoneURL]];
Jakub
  • 13,712
  • 17
  • 82
  • 139

3 Answers3

2

Try this.......

 UIWebView *callWebview = [[UIWebView alloc] init];   
    NSURL *telURL = [NSURL URLWithString:[NSString stringWithFormat:@"tel://%@", phoneNumber]
   [callWebview loadRequest:[NSURLRequest requestWithURL:telURL]];
Mudit Bajpai
  • 3,010
  • 19
  • 34
1

You can use the following code to get back to your app after making a call from your app

NSURL *url = [NSURL URLWithString:@"telprompt://phone number"];
[[UIApplication  sharedApplication] openURL:url];
Manju
  • 4,133
  • 2
  • 19
  • 12
0

There's no way to do that without jailbreaking.

Nikolai Ruhe
  • 81,520
  • 17
  • 180
  • 200
  • I stand corrected—though there seems to be some trouble with this approach: http://stackoverflow.com/questions/5317783 – Nikolai Ruhe Jun 06 '12 at 10:18