How to check Airplane mode in background in iPhone?

懵懂的女人 提交于 2019-12-04 05:35:48

问题



I have application which is working best with Wifi,3G.. Now what i want is i want to check in background if Airplane mode is going to be on at any moment and i want to popup alert saying "Airplane mode is On."
Thanks in advance.


回答1:


You can think different approach, check your mobile Network availability rather than the Airplane mode and Show a Generic Alert There is no network Available for example.

Check This link iphone-sdk-testing-network-reachability

Good luck




回答2:


This is practically impossible unless the user does it within a 10 minute time frame of your application entering background mode.



来源:https://stackoverflow.com/questions/5814947/how-to-check-airplane-mode-in-background-in-iphone

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!