I have a map annotation view that contains a rightcallout button which loads an accessory view which is a UIViewController class. I am using resuable annotations, but am wondering how I can pass updated information to my UIViewController class. Let's say I have 2 string values which map to 2 UILabels on my view. How can I update those values after the initial accessory view has already been loaded into memory as a resusable view?
Any help would be appreciated.
Is NSTimer auto retained?
Submit ajax form on keyboard close without a submit button on the iphone?
Why does this create a memory leak (iPhone)?
UICachedDeviceWhiteColor and NSAutoRelease for table cell mem leaks
Can I develop an iPhone app using java?
Lock orientation UIWebView on iPhone
How to ALTER sqlite column (iPhone)?
How to escape characters in href=mailto (iPhone)
Or, you could setup your annotation subclass to receive notifications (from NSNotificationCenter), and upon receiving a notification, update the title and the instance of your UIViewController class.. If you are unfamiliar with NSNotifications, then here is a quick reference.
I used these to keep my annotations updated.
This method is called when a user tapped one of the annotation view’s accessory buttons.
-(void)mapView:(MKMapView *)mapView annotationView:(MKAnnotationView *)view calloutAccessoryControlTapped:(UIControl *)control;
Assuming that your MKMapViewDelegate is also the UIViewController that can access your accessory view..