How to invoke a the zoom or pan with out trigger an event. I mean with out mouse scroll or click on zoom panel, how can i invoke the same in code level using a JS function.
How to invoke a the zoom or pan with out trigger an event. I mean with out mouse scroll or click on zoom panel, how can i invoke the same in code level using a JS function.
Thank You.
If you are using a tiledmapservice then you can go for
centerAndZoom(mapPoint, levelOrFactor)
use 0.5 to zoom in twice as far and 2.0 to zoom out twice as far.
or else you you go with map.setExtent(map.extent.expand(0.5)); for Zooming in and map.setExtent(map.extent.expand(2)); for Zooming out.
For Pan you can use the functions panUp(),pannDown(), panLeft(), panRight() You can find more about the map navigation hereand here