uppudada

Should Not include Basemap layer in Legend

Discussion created by uppudada on Aug 12, 2013
Latest reply on Aug 26, 2013 by uppudada
Hello,

         I have an issue about Legend. In my application i'm using basemap gallery.After map load base map is appears in legend. How to hide the basemap layer in legend. I tried the hidelayers concept (legend is not working), but no luck. Below i add the sample code and image.Anybody have solution for this?

         var legend = new esri.dijit.Legend({
       map : map,
     layerInfos: [{hideLayers: baseMapLayer}]
     }, "legendDiv");
      legend.startup();

                I used  updateLayerVisibility() method for layers on/off.

Thanks

[ATTACH=CONFIG]26643[/ATTACH]

Attachments

Outcomes