<ComboBox Name="cbDesignation" IsEditable="True" TextSearch.TextPath="DesignationName"
StaysOpenOnEdit="True" ItemsSource="{Binding Path=DesignationCollection,Mode=TwoWay}"
SelectedItem="{Binding Path=SelectedDesignation,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged,ValidatesOnDataErrors=True}"
VerticalAlignment="Center">
<ComboBox.ItemsPanel>
<ItemsPanelTemplate>
<VirtualizingStackPanel/>
</ItemsPanelTemplate>
</ComboBox.ItemsPanel>
<ComboBox.ItemTemplate>
<DataTemplate>
<TextBlock Text="{Binding Path=DesignationName}" VerticalAlignment="Center" Grid.Column="1" Margin="5,0,0,0"/>
</DataTemplate>
</ComboBox.ItemTemplate>
</ComboBox>
如果它是可编辑的,那么它会搜索但我只希望用户输入字母开头的一个项目,那么它将显示这个字母表中的所有列表