Returns the distance between the latitude/longitude coordinate specified by this GeoCoordinate and another specified GeoCoordinate.
| C# | Visual Basic |
public double GetDistanceTo( GeoCoordinate other )
Public Function GetDistanceTo ( _ other As GeoCoordinate _ ) As Double
- other (GeoCoordinate)
- The GeoCoordinate for the location to calculate the distance to.
The distance between the two coordinates, in meters.
The Haversine formula is used to calculate the distance.
The Haversine formula accounts for the curvature of the earth, but assumes a spherical earth rather than an ellipsoid.
For long distances, the Haversine formula introduces an error of less than 0.1 percent.
Altitude is not used to calculate the distance.