Welcome Christian
1.) This tutorial example determines driving distance HOW TO: Use the Navigate control using the MIT Navigate Map control. Use this example to calculate driving distance between two addresses or two pairs of geocoordinates . Documentation is Maps
2.) These two examples determine distance between two geocoordinates using a point to point distance calculation (not driving distance). The depend on having access to the location coordinates, not street address.
-
using the Map component and a Marker you can use these two Blocks to calculate
the distance between them in meters. Convert to whatever units you require. -
using a Great Circle distance algorithm
The Blocks with 6371 provides a result in metric units, the Blocks using 3959 results in English units.
There are many other options:
- use Google's Map Distance api Distance Matrix API overview | Distance Matrix API (Legacy) | Google for Developers
- use a service . There are several that charge for each distance calculation
- The Bing Maps REST APIs are generally free to use - They require you to sign up for a key first from https://www.bingmapsportal.com/.
The API for the Route service is at: Calculate a Route - Bing Maps | Microsoft Learn. It can return driving distances and routes plotted between up to 25 waypoints.
Conditions for use are at http://www.microsoft.com/maps/product/terms.html, but it's basically free for educational/non-profit use.
Regards,
Steve

