i use Find task query, i bind a combobox for layer selection,
now i have no idea how use combobox selected layer instated of this codes
FindParameters findParameters = new FindParameters();
// Layer ids to search
findParameters.LayerIds.AddRange(new int[] { 0,1,2,3,4,});
this is my binding codes
ComboBox x:Name="LayerNames" Grid.ColumnSpan="3" Margin="3,-21,2,74" HorizontalContentAlignment="Center" Grid.Column="2" SelectionChanged="LayerNames_SelectionChanged">
<ComboBox.ItemTemplate>
<DataTemplate>
<TextBlock Text="{Binding Value.Name}"/>
</DataTemplate>
</ComboBox.ItemTemplate>
</ComboBox>
Jennifer NeryAhmed El-SisiDominique BrouxHab G.ArcGIS API for Silverlight
Do you mean that you have many ArcGISDynamicMapServiceLayers and that you want to apply the FindTask to the layer selected from a combobox?
In this case, I would do it by code (at least in a first time) because you have to set the FindTask Url, the LayerIds and the searchfields which are all depending on the layer.
So likely easier to do it on the combobox 'SelectionChanged' event.