2013-05-28 91 views

回答

-1

你嘗試的MKMapView類的這個方法:

- (void)addAnnotations:(NSArray *)annotations; 

您應該將所有MKAnnotation對象添加到一個數組中,並調用類的方法與陣列。

例子:

NSMutableArray *filterLocs=[NSMutableArray array]; 

for (MKAnnotation *loc in YourMapPointsArray) 
{ 
//add some condition here to manipulate your map points 
[filterLocs addObject:loc]; 
} 

[self.mapView addAnnotations:filterLocs]; 

或只是讓普通

[self.mapView addAnnotations:YourMapPointsArray]; 
+0

是的,這很容易實現。我試圖一次性顯示註釋的所有「標註」。 [eventMap selectAnnotation:point animated:YES]; - 所有註釋。問題是蘋果只允許你一次顯示一個。 – user1530580

+0

我在我的地圖中執行此操作,並且所有註釋都在某個時間出現BTW我不想要任何動畫,因此該方法對我來說很好。 – satheeshwaran

+0

你能舉個例子嗎?不遵守。 – user1530580

相關問題