GetLatLngDistance (open)
Get the distance between two lat/long coordinates
Syntax
LOADLIB "wh::util/geo.whlib";
FLOAT FUNCTION GetLatLngDistance(RECORD latlng1, RECORD latlng2, RECORD options)
Parameters
RECORD latlng1
Coordinate 1
FLOAT lat
Latitute
FLOAT lng
Longitude
RECORD latlng2
Coordinate 2
FLOAT lat
Latitute
FLOAT lng
Longitude
RECORD options
Options
FLOAT radius
Radius to use (defaults to 6378137 to return a distance on Earth in meters)
Return value
FLOAT
The distance between the two coordinates in meters (assuming the default radius)