AnsweredAssumed Answered

Get Current coordinate on the map

Question asked by darksky21 on Dec 15, 2013
Latest reply on Dec 15, 2013 by darksky21
hi i would like to get the current coordinate of the user on the mapview.
i tried using AGSGeometryEngine to convert the coordinate i got from CLLocationManager as shown:

AGSPoint* gpsPoint = [[AGSPoint alloc] initWithX:location.coordinate.longitude                                                        y:location.coordinate.latitude                                         spatialReference:[AGSSpatialReference wgs84SpatialReference]];                  AGSGeometryEngine* engine = [AGSGeometryEngine defaultGeometryEngine];                  AGSPoint* mapPoint = (AGSPoint*) [engine projectGeometry:gpsPoint                                               toSpatialReference:self.mapView.spatialReference];

My question is how do i get the x and y coordinate in NSString instead of AGSPoint or AGSGeometry?

Is there another way to get the current coordinate?