@feroz

try to store the two points (whose distance you want to calculate) as
a simple linestring in a database with spatial features and make a
simple query for distance.

in mysql for example it is just this sql query commands:
mysql> SET @ls = 'LineString(1 1,2 2,3 3)';
mysql> SELECT GLength(GeomFromText(@ls));

http://dev.mysql.com/doc/refman/5.0/en/linestring-property-functions.html#function_glength

On 30 Sep., 09:30, Mike Williams <[EMAIL PROTECTED]> wrote:
> Wasn't it Indula Sumithraarachchi who wrote:
>
> >If browse the API you might find this
> > 
> >  var pointA = new GLatLng(d_lat, d_lng);
> >  var pointB = new GLatLng(d_lat, d_lng);
> >  distance = pointA.distanceFrom(pointB)/1000);
> >//Divide by 1000 to turn m to km
>
> But Feroz can't use that in a non-web application.
>
> --http://econym.org.uk/gmap
> The Blackpool Community Church Javascript Team
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Maps API" 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/Google-Maps-API?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to