Posts

Showing posts with the label MKReverseGeocoder

MKReverseGeocoder FindAddress

- (void)viewDidLoad {     [super viewDidLoad];     self.locationManager = [[[CLLocationManager alloc] init] autorelease];     locationManager.delegate = self;     locationManager.desiredAccuracy = kCLLocationAccuracyNearestTenMeters;     [locationManager startUpdatingLocation];     NSLog(@"%f",map.userLocation.coordinate.latitude);     NSLog(@"%f",map.userLocation.coordinate.longitude);     } - (void)locationManager:(CLLocationManager *)manager didUpdateToLocation:(CLLocation *)newLocation fromLocation:(CLLocation *)oldLocation {       // this creates a MKReverseGeocoder to find a placemark using the found coordinates     MKReverseGeocoder *geoCoder = [[MKReverseGeocoder alloc] initWithCoordinate:newLocation.coordinate];     geoCoder.delegate = self;     [geoCoder start]; } // this del...