开发者

iphone mkmapview

开发者 https://www.devze.com 2023-02-08 01:36 出处:网络
This is karthik. I am developing an app using mapview in iphone. I have to use two different pins to show user locations. That two users are different type . One user is belong to some category and an

This is karthik. I am developing an app using mapview in iphone. I have to use two different pins to show user locations. That two users are different type . One user is belong to some category and another one is some other category. I have to check that category and want to plot pin depend upon that category. When I try to do that, that pin is not showing properly. For a certain category it shows another pin, not what i set there. Can anyone help me?

What i need is i want to load two different pins in map depend upon some category. For example , if that category is shopping mall then i have to show building image then if there is any garden i have to show some other image at a same time not one by one . I want to plot two pins with different ca开发者_运维知识库tegory at the same time. For that,what could i do?

I tried lot of solution , but its not showing properly. Help me?


I did a solution just like that a while ago. I created a custom Annotation for each category. I then created a custom AnnotationView for each custom Annotation.

In the "- (MKAnnotationView *)viewForAnnotation:(id < MKAnnotation >)annotation" function I just returned the correct view depending on Annotation.

0

精彩评论

暂无评论...
验证码 换一张
取 消