Bogue
| Numéro d’ID de bogue | BUG-000152518 |
|---|---|
| Envoi | September 22, 2022 |
| Dernière modification | June 23, 2025 |
| S’applique à | ArcGIS Pro |
| Version trouvée | 3.0 |
| Système d’exploitation | N/A |
| Version du système d’exploitation | N/A |
| Statut | As Designed |
// Correct any input longitude values that extend beyond the date line
function Mod(value, range, upperEnd)
{
while (value > upperEnd)
value -= range;
var lowerEnd = upperEnd - range;
while (value <= lowerEnd)
value += range;
return value;
}
function LatLongToDMS(lat, lon)
{
lon = Mod(lon, 360, 180);
var dmsLat = ConvertDirection(abs(lat), {"directionType":"north", "angleType":"degrees"},
{"directionType":"north", "angleType":"dms", "outputType":"text", "format":'d[°] mm[\'] ss.ssss["] '})
+ iif( lat >= 0, "N", "S");
var dmsLon = ConvertDirection(abs(lon), {"directionType":"north", "angleType":"degrees"},
{"directionType":"north", "angleType":"dms", "outputType":"text", "format":'d[°] mm[\'] ss.ssss["] '})
+ iif( lon >= 0, "E", "W");
return dmsLat + ", " + dmsLon;
}
return LatLongToDMS(Geometry($feature).y, Geometry($feature).x);
Use the calculate geometry attributes tool or write an arcade expression to convert decimal degrees to Degree Minute Seconds (DMS) notation by referring to https://support.esri.com/en/technical-article/000008758.
ID de bogue: BUG-000152518
Logiciel:
Obtenir de l’aide auprès des experts ArcGIS
Télécharger l’application Esri Support