Hi,I'm having trouble showing the map coordinates in latitude/longitude in degrees (like "75° 9�?? 18.382�?� West longitude by 39° 59�?? 0.637�?� North latitude"). I followed this post , and came to this:
// Lat/Long.
else if (mapa.SpatialReference.WKID == 4326)
{
Point screenPoint = e.GetPosition(mapa);
MapPoint mapPoint = mapa.ScreenToMap(screenPoint);
Graphic ponto = new Graphic();
ponto.Geometry = mapPoint;
ponto.Geometry.SpatialReference = new SpatialReference(32640);
IList<Graphic> listaDePontos = new List<Graphic>();
listaDePontos.Add(ponto);
GeometryService servicoGeometrico = new GeometryService(@"http://gis.informs.conder.ba.gov.br/ArcGIS/rest/services/Geometry/GeometryServer");
servicoGeometrico.ProjectCompleted += (s, args) =>
{
IList<Graphic> results = args.Results;
Graphic projectedG = results[0];
CoordenadasDoMapa = string.Format("Coordenadas: N = {0}, E = {1}",
Math.Round(projectedG.Geometry.Extent.XMin, 4),
Math.Round(projectedG.Geometry.Extent.YMin, 4));
};
servicoGeometrico.ProjectAsync(listaDePontos, new SpatialReference(4326));
}But this doesn't show in Degrees, minutes and seconds.