[OpenLayers-Users] Getting the map scale while in layerswitcher redraw...

John Cole john.cole at uai.com
Sun Mar 11 23:47:45 EDT 2007


I'm working with Lance Dyas' modified LayerSwitcher and I've run into an
issue.  I need to tell the WMS GetLegendGraphic request the current scale.
I peeked at the scale control and used 'this.map.getScale()' and it isn't
returning the results I was expecting.  I put a string append in both the
layer switcher redraw and the scale control updateScale function to get a
trace of what OL thinks the scale is at each point.  Here are the results:

layer switcher> 442943842.5
layer switcher> 442943842.5
layer switcher> 442943842.5
layer switcher> 442943842.5
layer switcher> 442943842.5
updateScale> 442943842.5
updateScale> 216281.17309570312

The last scale 216K is what I was expecting back.  How can I get this scale
in the layer switcher redraw?

Thanks,

John

-- 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.5.446 / Virus Database: 268.18.8/718 - Release Date: 3/11/2007
9:27 AM
 
This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the sender. This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail.



More information about the Users mailing list