I have successfully managed to register a region or monitoring, I know this because the didStartMonitoringForRegion
method was fired.
I have a simple test app with one MKMapView
where I can see my current location, I also have my region drawn on the map as a red circle so I can actually 'physically' see at what point I am entering or exiting this region. In the didEnterRegion
and didExitRegion
methods I have a UIAlertView
that fires.
A little while ago I decided to leave the office and take a walk with my iPhone 4, to see if this would work. I started in the middle of the region (which is about 200m in radius), my app was in the foreground the whole time. I walked a couple blocks and exited the region, nothing happened.
I read on SO (I think) that sometimes it only works when you exit the region by a certain distance, so I kept on walking.
After another 200m or so I gave up as the UIAlertView
still wasn't showing, and started to walk back. Obviously, upon re-entering the region, didEnterRegion
wasn't firing either.
I am not calling [locationManager startUpdatingLocation]
anywhere in my code, should I be?? I'm only really creating the region and calling [locationManager startMonitoringForRegion]
.
The CLLocationManagerDelegate
is my app delegate, and it seems fine as my didStartMonitoringForRegion
is firing properly.
Am I missing anything else?