AnsweredAssumed Answered

Update map's zoom parameters after changing base layer

Question asked by Antenka on Sep 22, 2014

First of all: I'm using ArcGIS SDK for .Net (in WPF).

 

I've asked this question some time ago at  Geographic Information Systems Stack Exchange  , but got no answers ... one more shot.

 

I'm having the following issue:
Suppose I have a Map object and 2 base layers (a world map and a street map). A world map doesn't let us view the map too closely. The street map allows us to view as close as we want (almost). So, they have different scale parameters. Now, if I load the world layer first, like this (pseudocode):

map.Layers.Insert(0, WorldLayer);

and then switch layers:

map.Layers.Remove("WorldLayer"); 
map
.Layers.Insert(0, Streetlayer);

The map doesn't allow me to get closer than a WorldLayer allowed. SO, actually, I can't view a street view normally.

BUT, if I load a detailed map first:

map.Layers.Insert(0, Streetlayer);

and then switch layers:

map.Layers.Remove("Streetlayer"); map.Layers.Insert(0, WorldLayer);

In this case I can freely view trees near my home And even if I switch back, the WorldLayer would allow me to get closer than it allowed before.

I suppose there should be a way to update a map, to renew scale/zoom parameters for a new set of layers. Is anyone aware of a way to achieve that?

Outcomes