AnsweredAssumed Answered

Customized LayerList Selection

Question asked by hlynur.ingolfsson on May 2, 2017
Latest reply on May 3, 2017 by rscheitlin

Hello.

 

I am working with a mapservice that is built both on featureLayers and mapImageLayers and I would like the layerList tool for the service to only be applicable for the mapImageLayers, that is that only they are visible in the layerList tool and thus the only layers that can be turned on or off.

 

To clarify a bit then I need to have mapImageLayers as I need the "tree function" for them, that is the main layers and sublayers under them to be on-and-off selectable. I however also need to have a search function (look within the dataset that is) and a pop-up function so thus I use the featureLayers, though they are built on the same dataset as the mapImageLayers, so I just add them to the service and set opacity to '0'. Problem with this is that now both the mapImageLayers and the featureLayers appear in the layerList widget.

 

So maybe there is a better way to do this, where one can rely only on mapImageLayers or featureLayers for the following functionality:
layerList with a tree of sublayers.

Search function.

Nice Pop-Ups.

 

If so then it would be nice to get any comments on that instead/also.

Outcomes