【发布时间】:2012-10-03 07:13:44
【问题描述】:
我以这种方式向我的地图添加注释:
MyAnnotation *annotationPoint2 = [[MyAnnotation alloc] init];
annotationPoint2.coordinate = anyLocation;
annotationPoint2.title = [NSString stringWithFormat:@"%@", obj];
annotationPoint2.subtitle = @""; //or set to nil
annotationPoint2.keyValue = [NSString stringWithFormat:@"%@", key];
[mapPins addAnnotation:annotationPoint2];
别针都是红色的,我希望它们都是绿色的。我怎样才能改变颜色?我已经尝试了以下方法,但它仍然给出了一个红色标记:
annotationPoint2.pinColor = MKPinAnnotationColorGreen;
【问题讨论】:
标签: ios mkmapview mkpinannotationview