Hi all,
i've define a cllocation var and if nil, i'll give my newlocation value in delegate
-(void) locationManager:(CLLocationManager *)manager didUpdateToLocation:(CLLocation *)newLocation
fromLocation:(CLLocation *)oldLocation {
if (myStart == nil) {
self.myStart = newLocation;
when i call
if ([myStart respondsToSelector:@selector(distanceFromLocation:)]){
distance = [myStart distanceFromLocation:newLocation];
} else if ([myStart respondsToSelector:@selector(getDistanceFrom:)]){
distance = [myStart getDistanceFrom:newLocation];
}
totaldistance.text = [NSString stringWithFormat:@"%5.2fkm", distance / 1000] ;
starting point starts ever from a value that is not "0.00".
in which way i can do?