Share via


LatLong.Longitude Property

LatLong.Longitude Property

The longitude coordinate as a decimal degree value in World Geodetic System (WGS 84) datum. Valid values range from -180.0 through +180.0.


Public Longitude As System.Double = 0


[C#]

public System.Double Longitude;

Example

[Visual Basic]

'Calculate a route between two latitude and longitude coordinates
Dim latLongs(1) As LatLong
latLongs(0) = New LatLong()
latLongs(0).Latitude = 40
latLongs(0).Longitude = -120
latLongs(1) = New LatLong()
latLongs(1).Latitude = 41
latLongs(1).Longitude = -121

Dim myRoute As Route
myRoute = routeService.CalculateSimpleRoute(latLongs, "MapPoint.NA", SegmentPreference.Quickest)



[C#]

//Calculate a route between two latitude and longitude coordinates
LatLong[] latLongs = new  LatLong[2];
latLongs[0] = new LatLong();
latLongs[0].Latitude = 40;
latLongs[0].Longitude = -120;
latLongs[1] = new LatLong();
latLongs[1].Latitude = 41;
latLongs[1].Longitude = -121;

Route myRoute = routeService.CalculateSimpleRoute(latLongs, "MapPoint.NA", SegmentPreference.Quickest);


See Also

  LatLong Class