0

Lets consider I have two application App A and App B. What I want to do is

1) I like to open an App B when I tap on a button in App A.

2) When the App B is open from that button tap from App A, I like to go back to App A from App B.

Is it possible in iOS ?

Thank you, -- Amit

AAV
  • 3,785
  • 8
  • 32
  • 59
  • (1) is possible if App B has a URL scheme; (2) is possible if App B is set up to do that kind of thing. Google "iOS URL scheme" for more information. – bdesham Feb 14 '13 at 17:13
  • 1
    Don't forget to implement [x-callback-url](http://x-callback-url.com/)! – gav Feb 15 '13 at 22:36

2 Answers2

3

Very Possible. It is solved with custom url schemes that you're app states:

How to register a custom app opening URL scheme with Xcode 4?'

Launch an app from within another (iPhone)

Then from App A tell UIApplication to launch App B's url and vice versa.

Community
  • 1
  • 1
utahwithak
  • 6,235
  • 2
  • 40
  • 62
2

It is possible if both application support it.

Both application can declare an URL scheme they handle, e.g. applicationA://. Opening the application can then be performed by

NSURL* url = [NSURL URLWithString:@"applicationA://launch"];
BOOL success = [[UIApplication sharedApplication] openURL:url];

See Implementing Custom URL Schemes

Sulthan
  • 128,090
  • 22
  • 218
  • 270