mkannotation

Can I ignore this iphone warning?

Hi there I have this code: if([annotation respondsToSelector:@selector(tag)]){ disclosureButton.tag = [annotation tag]; } and I get the warning: '-tag' not found in protocol Fair enough, but I've created a new object with the protocol that has a synthesized int tag variable. EDIT: found why the app was crashing - not this...

Distance between 2 MKAnnotations ?

I am nearly sure, that i have seen a method (provided by the Apple-SDK) a time ago, that could find the distance between 2 MKAnnotations. That time i havent seen a use in the funktion. But, how it goes, now i would like to have this function but i can´t find it anymore. Can anyone please help me ? Maybe i have just something wrong in my...

iphone mapview bring first and last annotation to the front

I need some code which can be used outside of the mk* functions. I need to run my custom function to bring the FIRST and LAST markers in an array to the front. (so on top of all the other markers on my screen). I have tried [self.view bringSubviewToFront:[[mapView annotations]objectAtIndex: 0]]; I have used [[mapView annotations]objec...

iOs why must I implement setCoordinate to have my Annotation move in MKMapKit?

Hi, I am writing an iPad application (os 3.2) which uses MKMapKit to display moving annotations on the map. Information is retrieved via XML from three different sources and collated together in my Annotation class and then displayed on the Map. This information is coming in every 5 seconds. I had this working fine for a few months w...

Can't seem to remove any annotations.

I have some pins that the user can add. In the callout there is a button. When the user presses the button, I want a new pin to drop in that location, and I want to get rid of the pin that the user pressed (different types of pins). Basically the first pin is draggable, and when the user has found a proper location they will "lock" it....

Set MKMapView region to center on two annotations

I'm looking for some help with finishing some code on setting the region on a MKMapView based on the current location annotation and an annotation I have set. I want to calculate the distance between the two and set the center between the two and then zoom out so both are in view. It appears to work fine in Simulator for me, but unfortu...

Can I reposition an MKAnnotationView that's already been placed on a MKMapView?

Every few seconds I'm retrieving an updated lat and lon for a real-world object that is in motion. This object is represented on my MKMapView by an MKAnnotationView. Is it possible to smoothly animate the object's movement from coordinate to coordinate, rather than remove its current MKAnnotationView and add a new one at the new coordi...

MKMapView annotation position update problem

I need to track user current location with realtime refreshrate I have one function with two solutions for that. (void)locationManager:(CLLocationManager *)manager didUpdateToLocation:(CLLocation *)newLocation fromLocation:(CLLocation *)oldLocation { ifdef Variant_1 if(m_currentLocation) [m_Map removeAnnotation:m_currentLocation...