wpf-devexpress-dot-xpf-dot-editors-dot-autosuggestedit-c2851fbd.md
Gets or sets a template that defines the presentation of items contained within the drop-down list. This is a dependency property.
Namespace : DevExpress.Xpf.Editors
Assembly : DevExpress.Xpf.Core.v25.2.dll
NuGet Package : DevExpress.Wpf.Core
public DataTemplate ItemTemplate { get; set; }
Public Property ItemTemplate As DataTemplate
| Type | Description |
|---|---|
| DataTemplate |
A DataTemplate object that represents the template which defines the presentation of items contained within the drop-down list.
|
You can apply different templates to editor’s drop-down items using a custom logic implemented in the ItemTemplateSelector.
<dxe:AutoSuggestEdit
TextMember="City"
DisplayMember="City"
QuerySubmitted="AutoSuggestEdit_QuerySubmitted">
<dxe:AutoSuggestEdit.ItemTemplate>
<DataTemplate>
<StackPanel Orientation="Horizontal" >
<TextBlock Text="City:" Width="30"/>
<TextBlock Text="{Binding City}" Width="100"/>
<TextBlock Text="Customer:" Width="60" HorizontalAlignment="Right"/>
<TextBlock Text="{Binding Name}" Width="120"/>
</StackPanel>
</DataTemplate>
</dxe:AutoSuggestEdit.ItemTemplate>
</dxe:AutoSuggestEdit>
See Also