I was wondering if anyone else has encountered this and has a workaround:
I have created a map with the javascript API which uses the basemapGallery widget. The default map is dark-gray, which has a max zoom level of 16. If the user changes the basemap to Imagery with Labels ("hybrid"), they still can only zoom to a max level of 16, and not to 19, which the hybrid map supports.
If I set the default map to hybrid, the max zoom level works as it should.
Setting the maxZoom when initiating the map does not make a difference.
Solved! Go to Solution.
Michael,
If you are going to use a basemap that does not have all the LODs that other basemaps do as the default then you need to manually add the LODs to the maps constructor argument:
Map | API Reference | ArcGIS API for JavaScript
Look for the LOD section of the maps constructor option properties.
You can get the LODs json string from the basemap service like this:
http://services.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer?f=pjson
Michael,
If you are going to use a basemap that does not have all the LODs that other basemaps do as the default then you need to manually add the LODs to the maps constructor argument:
Map | API Reference | ArcGIS API for JavaScript
Look for the LOD section of the maps constructor option properties.
You can get the LODs json string from the basemap service like this:
http://services.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer?f=pjson
That did the trick Robert, thank you!