OpenURL not working when app is in background in iOS

I am trying to open one url in Safari from my application when the application is in background, below is my code

    [[UIApplication sharedApplication]openURL:[NSURL URLWithString:strURL]];

      

My application is typing the line above while debugging, but it won't open Safari with the given URL.

+3


source to share


1 answer


This is not possible, you cannot launch another application from background state. If the application is in the background, then you cannot have any event to process your application from the iPhone / iPad screen. You will need to wake up your application. You can use local notifications.



0


source







All Articles