Re: [mapguide-users] web layout script
This works for me: var myMap=parent.parent.mapFrame; var X=myMap.GetCenter().X; var Y=myMap.GetCenter().Y; var Scale=prompt(Enter Scale: ,); var newScale=parseInt(Scale); ZoomToView(X,Y,Scale,true); -- View this message in context: http://osgeo-org.1560.x6.nabble.com/web-layout-script-tp5175525p5176465.html Sent from the MapGuide Users mailing list archive at Nabble.com. ___ mapguide-users mailing list mapguide-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapguide-users
Re: [mapguide-users] web layout script
Mal, If you like the alert function. You will fall in love with console.debug() The console.debug don't give you an alert message but a log in the console. Be careful, console.debug doesn't work with IE !! So use Chrome (with development tool) or Firefox (with the plugin Firebug) and the result will be better. In place of object, you will have the description of the object with all the properties. 2014-12-04 14:23 GMT+01:00 GordonL gordon.luck...@arrowgeomatics.com: This works for me: var myMap=parent.parent.mapFrame; var X=myMap.GetCenter().X; var Y=myMap.GetCenter().Y; var Scale=prompt(Enter Scale: ,); var newScale=parseInt(Scale); ZoomToView(X,Y,Scale,true); -- View this message in context: http://osgeo-org.1560.x6.nabble.com/web-layout-script-tp5175525p5176465.html Sent from the MapGuide Users mailing list archive at Nabble.com. ___ mapguide-users mailing list mapguide-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapguide-users ___ mapguide-users mailing list mapguide-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapguide-users
Re: [mapguide-users] web layout script
I believe it is time for be to get reading glasses. I cut and pasted your code and it works. So obviously I have a typo somewhere. Thanks for all the help, at least I learnt a few tricks on how to debug i.e. alert and the tip from Jerome regarding console.debug cheers -- View this message in context: http://osgeo-org.1560.x6.nabble.com/web-layout-script-tp5175525p5176513.html Sent from the MapGuide Users mailing list archive at Nabble.com. ___ mapguide-users mailing list mapguide-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapguide-users