Select to view content in your preferred language

Flex Viewer - display LL widget without "More..." button

952
5
09-30-2010 12:30 PM
WilliamPollock
Occasional Contributor
Howdy �??

Exploring the latest ArcGIS Viewer for Flex and cannot seem to get the Map Switcher widget to not display the �??More�?��?� button while using the Layer List widget. Can get just the �??More�?��?� button to display without the Layer List widget, but not the other way around. Want the Layer List widget to show Operational Layers and not have the �??More...�?� button displayed.

http://help.arcgis.com/en/webapps/flexviewer/help/index.html

The Layer List Widget
�??NOTE: This widget offers similiar functionality found in the Map Switcher widget. Specifically, the "More..." button option that provides visibility control of operational layers. It is recommended to use either the Layer List widget OR the Map Switcher widget "More..." button for a Web mapping application, not both.�?�

The Map Switcher Widget
�??NOTE: With respect to displaying operational layers, this widget offers similiar functionality found in the Layer List widget. When designing the Viewer's capability to control the display of operational layers, it is recommended to use either the Map Switcher widget "More..." button OR the Layer List widget for a Web mapping application. It is not a best practice to have both enabled within the same Web mapping application.�?�

Appreciate any help. Thank you.

Cheers,
+ bill
Tags (2)
0 Kudos
5 Replies
SarthakDatt
Frequent Contributor
Hey William,

You could do that by updating the Map Switcher Widget's config file. There is a visible property on the <layerlist> tag which you can set to false to not show the "More" Button.

MapSwitcherWidget.xml :
<?xml version="1.0" ?>
<configuration>
    <layerlist label="More..." visible="false">
        <!-- <excludelayer>TheLabelOfSomeLayerInMainConfig</excludelayer> -->
    </layerlist>
</configuration>


Hope that helps.
0 Kudos
WilliamPollock
Occasional Contributor
Yahtzee!

Thank you sdatt.
That did it; i did not see the list of tags.

Cheers,
+ bill
0 Kudos
OranousDanandeh
Deactivated User
I tried adding the following to my mapswitcher.xml file and still the layers show up.
<layerlist label="More..." visible="true">
        <excludelayer>Pump Stations</excludelayer>
     <excludelayer>Large Scale Layers</excludelayer>
     <excludelayer>City Limits</excludelayer>
     <excludelayer>City Index</excludelayer>


would you please explain more on the comment you made
<excludelayer>TheLabelOfSomeLayerInMainConfig</excludelayer
the label of some layer in main config file.
The main config file under opreationlayers only has the map service name
<operationallayers>       
             <layer label="Layer Visibility" type="dynamic" visible="false" alpha="1.0"
                    config="widgets/LayerList/LayerListWidget.xml"
                   url="http://myserver/ArcGIS/rest/services/WaterMap/MapServer">
                  
             </layer>

</operationallayers>

Thanks,
Oranous Danandeh
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Oranous,

   I sounds like you want to exclude a certain layer of a map service for the Layer list. If that is the case than you can not do that. You can only exclude the whole map service.
0 Kudos
AYounas
Occasional Contributor
Hi,

I am having an issue here. I cannot see the more button on my map switcher but all my alyers are shown up correctly.

my mapswitcherwidget.xml file shows like:

"<configuration>
    <layerlist visible="true">
     <!-- <excludelayer>The Label Of Some Layer In Main Config File</excludelayer> -->
    </layerlist>
</configuration>"

I'll appreciate any help please.

Thanks,

Adi
0 Kudos