iPhone - do not receive significant location changes in iphone 3gs with iOS 4.2
-
31-01-2021 - |
Question
I am trying to execute the following code on my iPhone 3gs, with the OS version as iOS 4.2.1
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= 40000
[m_coreLocationMan startMonitoringSignificantLocationChanges];
#endif
It somehow does not work for me. It works on my iPhone 4, but not on iPhone 3gs with iOS4. Does anyone have any insight into the problem?
La solution
Check the return value of +[CLLocationManager significantLocationChangeMonitoringAvailable]
. If that says YES
on the problem device but you're still not getting any messages, then you have a problem; otherwise, it's the expected behavior.
Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow