I am trying the example for the legend shown HERE It does display the check boxes the way shown in the example. However, when I deselect any of the boxes the layer not only disappears from the map as intended but also goes away in the legend control... Is there any setting I need to change? Here is the XAML conde I'm using:<esri:Legend Name="legend1" Map="{Binding ElementName=map1}" LayerItemsMode="Tree"> <esri:Legend.MapLayerTemplate> <DataTemplate> <StackPanel Orientation="Horizontal"> <CheckBox Content="{Binding Label}" IsChecked="{Binding IsEnabled, Mode=TwoWay}" IsEnabled="{Binding IsInScaleRange}" > </CheckBox> <Slider Maximum="1" Value="{Binding Layer.Opacity, Mode=TwoWay}" Width="50" /> </StackPanel> </DataTemplate> </esri:Legend.MapLayerTemplate> <esri:Legend.LayerTemplate> <DataTemplate> <CheckBox Content="{Binding Label}" IsChecked="{Binding IsEnabled, Mode=TwoWay}" IsEnabled="{Binding IsInScaleRange}" > </CheckBox> </DataTemplate> </esri:Legend.LayerTemplate> </esri:Legend>
If you notice, it is exactly the same thing as in the example...