Select to view content in your preferred language

2.1 RC: Button in LegendItemTemplate removes the symbol.

419
1
12-08-2010 10:50 AM
KirkKuykendall
Deactivated User
Hi -

When I add a button the the LegendItemTemplate, I get a button for each legenditem, but the symbol for each legenditem is no longer there.  Is there someway to add to the controls already in this datatemplate instead of replacing them?

<esri:Legend.LegendItemTemplate>
                    <DataTemplate>
                        <Button Content="Select"  Click="Select_Click"/>
                    </DataTemplate>
</esri:Legend.LegendItemTemplate>
0 Kudos
1 Reply
dotMorten_esri
Esri Notable Contributor
The template is not "adding" to the other template, but replacing it. You need to also put the SymbolDisplay control in there as well. The easiest way to modify the existing template is doing it through Blend. Right click the control, select to modify additional templates and pick this template.
0 Kudos