yes, i think it gives the result travel distance by car. i want the travel distance . how can i get travel distance ?
On Sat, Oct 8, 2011 at 3:53 PM, Michael Banzon <[email protected]> wrote: > How do you get the result "using google maps"? Could the case be that > google maps simply gives you the travel distance by car/train/foot?? > > On Sat, Oct 8, 2011 at 12:19 PM, Chirag Raval > <[email protected]> wrote: >> I want to get the Distance between two latitude and longitude in >> meter / km . So i am using the below function . It gives me the >> different result than the google Map. >> >> Can you help me to solve my problem ? i dont understand What is the >> Problem ? >> >> Code >> >> float[] results = {0}; >> >> android.location.Location.distanceBetween(lat1, lon1, lat2, lon2, >> results); >> >> Current Latitude = 23.012281666666663 Current Longitude = >> 72.51798333333333 >> >> Destination Latitude = 23.1120487 Destination Latitude = 72.5766759 >> >> It gives this Result = 12579.679 in Meter, while in google map it >> gives this result = 17.9 Km >> >> I do not understand why this two gives the different result. >> >> -- >> You received this message because you are subscribed to the Google >> Groups "Android Developers" group. >> To post to this group, send email to [email protected] >> To unsubscribe from this group, send email to >> [email protected] >> For more options, visit this group at >> http://groups.google.com/group/android-developers?hl=en >> > > > > -- > Michael Banzon > http://michaelbanzon.com/ > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

