Search code examples
iphoneiosbackgrounduiapplicationdelegateuidevice

Application which work in background only iPhone


I have requirement for an application which work in background only.

When first time application install on device then after installation that will be go to background. And after two minutes a view will popup on screen.

Now problem is that after installation how to redirect application into background?

i get answer for this that if we want to send our app into background then we have to open another app like as safari. so i get this solution.

Now problem is that how show a view after two minutes from background. I have to create as a demo not for app store. So if anyone have any solution then suggest me.

Thanks


Solution

  • iOS is not designed to run code in the background. There are a few exceptions, for example a music streaming app, or a GPS navigation app, but in general it cannot be done.

    Instead, you should run your app on a server in the cloud, and send a push notification to the phone when you want something to happen on the phone. You may also be able to achieve this with "local notifications", depending on what you're trying to do.