On Dec 22, 11:18 am, supriya <[email protected]> wrote:
> Then lat1's value is shown as Nan.
That's because it's not a number. It's an array.
> var mg=new GLatLng(myArray[0]);
> var lat1=mg.lat();
GLatLng takes two numbers as arguments. You're not passing two
numbers, you are passing a single array element as the first argument
and the second is null.
You have
var marker=new GMarker(latlng);
myArray.push(marker.getLatLng());
which means that each array element is *already* a GLatLng object.
So what should work is
var mg=myArray[0];
If it doesn't work, please provide a link rather than a code listing.
Listings are not especially easy to debug and many people don't
bother. Those who do may miss something which a debugger like Firebug
wouldn't.
Andrew
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---