Switch on individual layers of a map with a button

10-26-2021 05:14 AM
Labels (1)
New Contributor

Hello all,

I have loaded a web map with different layers into Experience Builder to create a WebApp. In this web app, individual layers of the web map should be able to be switched on and off with a button or a switch.

Is this possible and do you have any tips on how I can implement this?

Many greetings

4 Replies
Esri Contributor

Hi, when adding the map widget to your Experience, there is an option to enable the "Layers" tool which will allow the end user of the app to toggle visibility of layers.




New Contributor III

It's different with a button that quickly turns on/off a layer. If a map has multiple layers, users might want a quick button to turn on a frequently used layer. 

0 Kudos
New Contributor II

Out of curiosity did you figure out a way to do this.  I sort of have a hacked method using the filter widget but it's not pretty.  The people we are making the map for really don't like the layer widget, they want easy to click buttons.

New Contributor

I am also interested in this - especially if you can create a button that will turn a group of layers on/off. 
@blairtinker, how did you do this with the filter widget? 

0 Kudos