Logger
Logger

Reputation: 1286

In iOS 8 Beacon not detecting

iBeacon suddenly stopped working in iOS8. Before it was working fine in previous iOS 8 versions. Anybody help me to come out from this problem?

What is the problem, Thanks

Upvotes: 2

Views: 2273

Answers (3)

user3306145
user3306145

Reputation: 76

just add following in to your viewdidload its works for me..

[locationManager requestWhenInUseAuthorization]; [locationManager requestAlwaysAuthorization];

Upvotes: 0

HeadOnn
HeadOnn

Reputation: 1490

What you need to do is to add request permission for accessing location services in the code, like the following:

if([self.locationManager respondsToSelector:@selector(requestAlwaysAuthorization)]) {
    [self.locationManager requestAlwaysAuthorization];
}

Also, in your app info.plist(AppName-info.plist), add the key "NSLocationAlwaysUsageDescription" by clicking on the '+' sign besides "Information Property List". Select its type as 'String', and add any string value that can be displayed in the alert to access location permission. I hope this solves your issue.


*Note: If you are building your own beacon sdk and integrating in the app, then please add key value pair in the info.plist of the app, and not that of the sdk. David Young's link also point in the right direction, but the problem was that you were adding key value pairs in the sdk's info.plist

Upvotes: 5

davidgyoung
davidgyoung

Reputation: 65015

You need to implement a new permissions model for beacons on iOS 8 building with XCode 6. See here: See here:

Location Services not working in iOS 8

Upvotes: 1

Related Questions