I am loading Multiple annotations onto my map view. These annotations displays as a pin when the map is loaded.
By using the below code i can display title directly for one annotation, but for remaining annotations user is required to tap on the pin for title to see.
I want to display the title for all the annotations when the Mapview Loaded without touching the annotation pin
NSMutableArray * locations = [[NSMutableArray alloc] init];
_myAnn = [[MKPointAnnotation alloc] init];
_locationCoordinate.latitude = 27.175015;
_locationCoordinate.longitude = 78.042155;
_myAnn.coordinate = _locationCoordinate;
_myAnn.title = @"A";
[locations addObject:_myAnn];
_myAnn = [[MKPointAnnotation alloc] init];
_locationCoordinate.latitude = 28.171391;
_locationCoordinate.longitude = 79.037090;
_myAnn.coordinate = _locationCoordinate;
_myAnn.title = @"B";
[locations addObject:_myAnn];
_myAnn = [[MKPointAnnotation alloc] init];
_locationCoordinate.latitude = 29.169005;
_locationCoordinate.longitude = 80.043206;
_myAnn.coordinate = _locationCoordinate;
_myAnn.title = @"C ";
[locations addObject:_myAnn];
[self.map_View addAnnotations:locations];
// i am using below method to display title for one annotation
// [self.map_View selectAnnotation:_myAnn animated:YES];
for (MKPointAnnotation *annotation in locations) {
[self.map_View selectAnnotation:annotation animated:NO];
}
MKCoordinateSpan span;
Span. latitudeDelta = 10;
Span. longitudeDelta = 10;
MKCoordinateRegion region;
region.span = span;
region.center = _locationCoordinate;
[self.map_View setRegion:region animated:YES];
Thanks in Advance..