Programmatically zoom in/out

1359
1
08-24-2018 12:35 PM
CharlesLoftis
New Contributor III

Using ArcGIS Android 100+...

In additional to pin/pull to zoom in/out I need to provide zoom in/out buttons.

Unfortunately I'm not seeing a straight forward way to accomplish this. I'm not even sure how to determine the current zoom level after loading my map from a mobile map package. Suggestions?

0 Kudos
1 Reply
CharlesLoftis
New Contributor III

Figured this out. Don't really know how I missed this... MapView class has methods:

  • getMapScale() returns the zoom level.
  • setViewpointScaleAsync(double scale) that zooms the map to the provided zoom level.

Using these two methods I am able to build programmatic zoom controls.

0 Kudos