MapPoint ActiveX Control offers two methods to perform zoom operations on the maps.

1.ZoomIn method – This method zooms the map view closer by reducing the map altitude
2.ZoomOut method – This methods zooms the map view farther by increasing the map altitude

These two methods zoom in/out in steps. There are ten levels of zoom effect that you can achieve using these two methods. The levels are defined based on the map altitude and each time when you call zoom methods, map’s altitude is modified accordingly and re-rendered to show the map at that altitude.
The following code shows how to call a ZoomIn method:

axMappointControl1.ActiveMap.ZoomIn();

Now, if you want to zoom into a particular level from your current view, say, you want to zoom to street level directly without calling ZoomIn method multiple times, you can do that by modifying the map altitude, as shown below:

//Zoom directly into Street Level by setting 3 mile altitude
axMappointControl1.ActiveMap.Altitude = 3;

To learn more about this topic and other related topics, please buy Programming MapPoint in .NET

0 comments