GraphHopper.com | Forum | GitHub | Maps | Blog

Get total distance in mile based on lat long


#1

Hello,

I am using Graph hopper in my MVC Application. I want to get total travel miles on the basis of latitude and longitude. basically, I have customer address and on the base of it I’ll get longitude and latitude. base on all lat-longs, I want to get total distance in miles.

Thanks.


#2

First use the Geocoding API to convert the customer addresses into lat-longs. Then use the Routing API (or Matrix API) to fetch the distance in meter and convert this in miles using the 1.609344 factor.