Geofencing Tutorial with Core Location

Iā€™m also having same error:
ERROR /BuildRoot/Library/Caches/com.apple.xbs/Sources/VectorKit_Sim/VectorKit-1230.32.8.29.9/GeoGL/GeoGL/GLCoreContext.cpp 1763: InfoLog SolidRibbonShader:
ERROR /BuildRoot/Library/Caches/com.apple.xbs/Sources/VectorKit_Sim/VectorKit-1230.32.8.29.9/GeoGL/GeoGL/GLCoreContext.cpp 1764: WARNING: Output of vertex shader ā€˜v_gradientā€™ not read by fragment shader

but when I use it in iPad it shows following error:

Geotify[3692:2523806] [LogMessageLogging] 6.1 Unable to retrieve CarrierName. CTError: domain-2, code-5, errStr:((os/kern) failure)

Where it says ā€œlets you make coolsā€ I think is a typo.

Great tutorial! I was wondering if there was a way to show the overlay outside of the circle when ā€œOn Exitā€ is clicked. Kind of like how it does in the iOS reminders app. Thanks in advance!

When i put a breakpoint , in the exit, the alert not appear ā€¦

Thanks for this awesome tutorial! I noticed a small little migration oversight from the old Swift 2.x code.

When you update the calloutAccessoryControlTapped method from the MK Delegate, the syntax for removeGeotification(_:) changed to remove(geotification:)

Thanks for this great tutorial. i changed the workflow of this app in accordance with my requirements. I am sending coordinate ,radius and notes from server and i want single geofenced region to work both for on exit and on entry events but there is little problem if i want to create 4 geofences its creating 8 geofences(each geofence is duplicating with the exact coordinate) and on test locations events are triggering properly but when checking with real locations its not working.

Quick response will be highly appreciated.Thanks!!!

I want to know that this also works when my app is totally closed.If no then please refer any tutorial

When I use my iphone 7 PLUS,
I got an error:
Error Domain=kCLErrorDomain Code=5
but simulator work fine.

I know whatā€™s the problem.
I add the code ā€œlocationManager.requestStateā€,
So got the error.

Hi, I am following the Tutorial but I get this error in the story board "static table views are only valid when embedded in UITableViewController instances"how do I fix this

Thank you for the tutorial!

I was wondering if there was a way to change the alert thatā€™s shown when the application is active from ā€œOKā€ to a ā€œYES/NOā€ option.

Thanks again!

Thanks for this tutorial! One important thing to notice is this:

class GeotificationsViewController: UIViewController {

  @IBOutlet weak var mapView: MKMapView!

  var geotifications = [Geotification]()
  let locationManager = CLLocationManager() // <-- This one

  // ...
}

The location manager has to be retained for this to work (instance variable/property in this case). If you use a local variable for viewDidLoad, the authorization dialog will disappear automatically just after the location manager object is freed. Sometimes without interacting with it at all.

In Objective-C, you should use a strong property to retainā€¦

@interface AppDelegate ()
@property (strong, nonatomic) CLLocationManager *locationManager;
@end

ā€¦ or an instance variable.

@implementation AppDelegate {
    CLLocationManager *locationManager;
}

Great tutorial. I am writing an app for navigating the blind. This program helps a lot. I need to enhance this so that as the person is moving, the ap should help the person stay on the predetermined course by giving cues if person moves too far from the predetermined lat/long. I am thinking I should have a circle around each lat/long to establish continuous geo-fencing.

Does that make sense?

Thanks
Ram

This was awesome! Thank you for all your time and effort. Iā€™m having a problem where DidEnterRegion is firing outside of my region. Iā€™m running on my device and after a few minutes of loading the app, I start getting all my geofence alerts. Iā€™m nowhere near any of the locations. Any ideas?

Hi,

Thank you for the post. I have geo-fencing locations nearing 500 (pubs and restaurants). Does the app manage to track all 500 ?

This tutorial is more than six months old, so questions are no longer supported at the moment for it. We will update it as soon as possible. Thank you! :]