仅在iPhone后台运行的应用程序 [英] Application which work in background only iPhone

查看:138
本文介绍了仅在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?

我得到的答案是,如果我们想将我们的应用程序发送到后台,那么我们必须打开另一个应用程序,例如safari.所以我得到了这个解决方案.

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.

谢谢

推荐答案

iOS并非旨在在后台运行代码.有一些例外,例如音乐流应用程序或GPS导航应用程序,但通常无法完成.

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.

这篇关于仅在iPhone后台运行的应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆