Select to view content in your preferred language

Bing maps get Distance between two places

2611
3
09-12-2012 02:45 AM
SantoshV
Emerging Contributor
Hi,
I have referred the sample http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#BingRouting and developed a Bing maps routing tool on my Silverlight GIS website..
now my client wants me to also show the distance between two places whos direction is shown.. I took a look at the Routing class but failed to find anything to get the distance..
I used the �??haversine�?? formula, but it does not give me the exact distance along the route..
or
Can I calculate the length of the geometry/polyline drawn on the map.. Will this result be accurate?

Please guide me so that I can get the distance between my start and destination..
0 Kudos
3 Replies
ChristopherHill
Deactivated User
Have you tried using the distance geometry service on ArcGIS Server. You will need to project to an equal area spatial reference before sending geometry in order to get a accurate distance.
0 Kudos
AbdulrahmanTaher
Emerging Contributor
You can get it from the ''' Summary Class ''' which have distance and times

routeleg.Summary.Distance


i hope that what you want.
0 Kudos
SantoshV
Emerging Contributor
Abdulrahman Taher,
Thanks a bunch this is exactly what I was looking for,.. you save me....
0 Kudos