Select to view content in your preferred language

Default Graphics Layer not staying on top

564
0
01-13-2011 09:18 AM
DanielScholes
Emerging Contributor
Hi,

I have been developing a map interface using the Javascript API 2.1. I use the dojo drag and drop with custom code to reorder the layers in the map. Each layer is from a separate service (9.3.1). There are currently a total of 37 layers (basemaps and feature layers) that can be toggled off and on and ordered.

The problem I am experiencing is that once I reorder the feature layers, the default graphics layer (used for zoom interaction and drawing extents) sometimes displays behind some of the other feature layers.

I tried to even manually reorder the default graphics layer, without success.
Neither of these worked:
x = the layer id it should be to stay on top
map.reorderLayer(map.graphics,x);
map.reorderLayer(map_graphics,x);

Has anyone experienced this type of issue? Are there any known work arounds?

I have been using Firebug to look for an undocumented method or something to refresh the map, which might reorder the layer to the top.

Thank you for viewing my issue.
Dan Scholes
Applications Programmer
Washington University
Earth and Planetary Sciences
0 Kudos
0 Replies