I am getting below error, while adding annotation
An instance 0x21fcadd0 of class MKPointAnnotation
was deallocated while key value observers were still registered with it. Observation info was leaked, and may even become mistakenly attached to some other object. Set a breakpoint on NSKVODeallocateBreak
to stop here in the debugger.
Here's the current observation info:
( Context: 0x0, Property: 0xb74f170> )
my code is below putting pin more than 100.
if ([arrListing count] != 0) {
for (int i = 0; i < [arrListing count]; i++) {
Listing *obj = [arrListing objectAtIndex:i];
NSLog(@"Title %@ long:%@ Lat:%@",obj.Title,obj.log,obj.lat);
CLLocationCoordinate2D annotationCoord;
annotationCoord.latitude = [obj.lat floatValue];
annotationCoord.longitude = [obj.log floatValue];
// do something
MKPointAnnotation *annotationPoint = [[MKPointAnnotation alloc] init];
annotationPoint.coordinate = annotationCoord;
annotationPoint.title = obj.Title;
// annotationPoint.subtitle = obj.log;
[mapView addAnnotation:annotationPoint];
}
}
}
thank in advanced