Here's my big problem. My mapView is running with an error when I'm adding "Assetlibrary.Framwork". If I remove the library, my mapView is go fine. Why? Here's my mapview code: (p.s I'm using storyboard)
.h
@property (strong, nonatomic) IBOutlet MKMapView *MapView;
.m
viewdidload:
MapView.delegate = self;
[self setLocationManager:[[CLLocationManager alloc] init]];
[locationManager setDelegate:self];
[locationManager setDistanceFilter:kCLDistanceFilterNone];
[locationManager setDesiredAccuracy:kCLLocationAccuracyHundredMeters];
[locationManager startUpdatingLocation];
- (void)locationManager:(CLLocationManager *)manager
didUpdateToLocation:(CLLocation *)newLocation fromLocation:(CLLocation *)oldLocation {
if ((oldLocation.coordinate.longitude != newLocation.coordinate.longitude)
|| (oldLocation.coordinate.latitude != newLocation.coordinate.latitude)) {
coord.latitude = newLocation.coordinate.latitude;
coord.longitude = newLocation.coordinate.longitude;
region.center = coord;
span.latitudeDelta = 0.05;
span.longitudeDelta = 0.05;
region.span = span;
}
And Here's my error:
'NSUnknownKeyException', reason: '[ setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key MapView.'
Am I setting my mapview twice? or something I did wrong?