> map.getCenter().lng() will return the longitude... Ah so I wasn't far off (was just missing the () bits ;))
Can you tell I'm not a JS coder by nature? ;) Thanks! Andy On Mar 17, 1:39 pm, "[email protected]" <[email protected]> wrote: > On Mar 17, 6:35 am, youradds <[email protected]> wrote: > > > Thanks for the replies guys...but how do I use that? > > > I've tried: > > > alert("TESTING: " + map.getCenter.lng); > > > ..which says that function doesn't exist (which I was expecting) > > Have you seen Mike Williams' tutorial? Lots of working examples > there... > > map.getCenter() will return a GLatLng > > map.getCenter().lng() will return the longitude... > > (all assuming your GMap2 variable is called "map" and is in the > current scope, which I can't tell because you didn't follow the > posting guidelines and post a link to your map that shows the > problem...) > > -- Larry > > > > > ..and : > > > alert("TESTING: " + map.getCenter); > > > ..gives me this output: > > > TESTING: function () { > > return this.oc; > > > } > > > Any suggestions are appreciated :) > > > TIA > > > Andy > > > On Mar 17, 1:29 pm, Andrew Leach <[email protected]> > > wrote: > > > > On Mar 17, 1:16 pm, youradds <[email protected]> wrote: > > > > > How would I go about getting the center value (on the map) of the > > > > current view? > > > >http://code.google.com/apis/maps/documentation/reference.html#GMap2.g... > > -- 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.
