Select to view content in your preferred language

Layer List

469
1
Jump to solution
08-20-2019 05:34 AM
jaykapalczynski
Honored Contributor

Wondering if anyone has any examples of turning on and off Feature layers in an appstudio app

Is there something like visible = false?  

Can I turn them on and off

            FeatureLayer {
                ServiceFeatureTable {
                    url: "http://sampleserver6.arcgisonline.com/arcgis/rest/services/Energy/Geology/FeatureServer/9"

                }
            }

Something like this

0 Kudos
1 Solution

Accepted Solutions
ErwinSoekianto
Esri Alum

Jay, 

We have similar functionality in Map Viewer template where you can turn layers on and off, on Map details -> Content panel, see image below. 

And the code to do this is at MapViewer/views/PanelPage.qml, where we set the visible property of the layer to false. 

I hope this is helpful,

Erwin

View solution in original post

0 Kudos
1 Reply
ErwinSoekianto
Esri Alum

Jay, 

We have similar functionality in Map Viewer template where you can turn layers on and off, on Map details -> Content panel, see image below. 

And the code to do this is at MapViewer/views/PanelPage.qml, where we set the visible property of the layer to false. 

I hope this is helpful,

Erwin

0 Kudos