可能重复:
GPS coordinates in degrees to calculate distances使用GPS地图如何计算两点
使用GPS我capure的串串如何在字符串<分开纬度和经度+37.33168900,-122.03073100> +/- 100.00m(速度-1.00 mp/course -1.00)@ 2011-08-26 12:56:57 +0530
当我打电话给位置管理员R这是方法被称为
// Delegate method from the CLLocationManagerDelegate protocol.
- (void)locationManager:(CLLocationManager *)manage didUpdateToLocation:(CLLocation *)newLocation fromLocation:(CLLocation *)oldLocation
{
[email protected]("%@",newLocation) //<+37.33168900, -122.03073100> +/- 100.00m (speed -1.00 mp/course -1.00) @ 2011-08-26 12:56:57 +0530
[email protected]("%@",oldLocation) //null
}
我的问题是如何将我的老位置,以及如何保存到使用newlocation和oldlocation如何计算我搜索谷歌的距离,但我不能找到,请帮助我。我很难为如何保存oldLocation。
-1你可以更具体一点吗? – JohnJohnGa