I'm working on an app that manages my own URL scheme so I implement the callback:
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions (NSDictionary *)launchOptions
{
// Get our launch URL
if (launchOptions != nil)
{
// Launch dictionary has data
NSURL* launchURL = [launchOptions objectForKey: UIApplicationLaunchOptionsURLKey];
// Parse the URL
NSString* hostString = [launchURL host];
blah blah blah...
It works very nice but I need to launch the caller application (i.e. the app that opened the URL). So my question here is, is it possible?
I have been playing with UIApplicationLaunchOptionsSourceApplicationKey
but I can't launch back the app by its application Bundle ID. Can I?
I have also tried the undocumented launchApplicationWithIdentifier:
of UIApplication
, but I need a real solution and it seems that workaround only works in the Simulator.
Any ideas? Thank you!