マップポイントの緯度と経度の値を整数としてデータベースに保存します。
したがって、私の値は3454534353のようになります。ただし、使用する場合は、フロートを34.54534353として使用する必要があります。
どうすればこの変換を行うことができますか?
マップポイントを作成する方法は次のとおりです。
MapLocation *location = [[MapLocation alloc] init];
location.title = [NSString stringWithString:[locations objectForKey:@"title"]];
location.subtitle = [NSString stringWithString:[locations objectForKey:@"subtitle"]];
CLLocationCoordinate2D coordinate;
coordinate.latitude = // need a float like xx.xxxxx
coordinate.longitude = // need a float like xx.xxxxx;
location.coordinate = coordinate;
[annotations addObject:location];
[mapView addAnnotations:annotations];
前もって感謝します。