在xcode中每半小时后调用一个函数

时间:2012-08-30 08:04:50

标签: objective-c xcode

我想在后台每半小时调用一次函数。

描述:我已经调用了一个函数 - (void)applicationDidEnterBackground:(UIApplication *)application方法。我需要在每半小时后重复一次这个功能。请帮我这样做。如果您需要任何细节,请告诉我。

1 个答案:

答案 0 :(得分:0)

当您的应用在function时,您无法运行任何background,直到您的应用支持这些 -

Apps that play audible content to the user while in the background, such as a music player app

Apps that keep users informed of their location at all times, such as a navigation app

Apps that support Voice over Internet Protocol (VoIP)

Newsstand apps that need to download and process new content

Apps that receive regular updates from external accessories

有关您可以在后台执行的操作以及如何操作的更多详细信息,请访问 -

http://developer.apple.com/library/ios/#DOCUMENTATION/iPhone/Conceptual/iPhoneOSProgrammingGuide/ManagingYourApplicationsFlow/ManagingYourApplicationsFlow.html