Topics   All   MacOS (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server   Client   Old   Deprecated   Guides   Examples   Videos
New in version: 10.4   10.5   11.0   11.1   11.2   11.3   11.4   11.5   12.0   12.1    Statistic    FMM    Blog  

CoreLocation.distanceFromLocation

Returns the distance (in meters) from the receiver's location to the specified location.

Component Version macOS Windows Linux Server iOS SDK
CoreLocation 2.7 ✅ Yes ❌ No ❌ No ❌ No ✅ Yes
MBS( "CoreLocation.distanceFromLocation"; latitude; longitude )   More

Parameters

Parameter Description Example
latitude The latitude value for the geo coordinate. 51.50939
longitude The latitude value for the geo coordinate. -0.11832

Result

Returns distance in meters.

Description

Returns the distance (in meters) from the receiver's location to the specified location.
This method measures the distance between the two locations by tracing a line between them that follows the curvature of the Earth. The resulting arc is a smooth curve and does not take into account specific altitude changes between the two locations.

Examples

Return distance from London

MBS( "CoreLocation.distanceFromLocation"; 51.50939, -0.11832)

Example Databases

Created 18th August 2014, last changed 18th August 2014


CoreLocation.distanceFilter - CoreLocation.hasLocation

Feedback: Report problem or ask question.




Links
MBS Xojo Plugins

Start Chat