A customer recently opened a support case asking for a sample of a grid-like drop-down (i.e., multiple columns with a single header) in a XamComboEditor. The reply below contains the sample; I hope this sample will be useful to others...
There are a couple of comments in the XAML at the places where I had to change the default templates.
I changed the default template of both the XamComboEditor control, and the ComboEditorItemControl, then used the ItemTemplate in thecontrol to make this work.
· In the XamComboEditor I added another Grid panel to the template to add the headers in the popup.
· In the ComboEditorItemControl I changed the container that holds the checkbox and the items contentpresenter so that the content would stretch to the width of the popup.
· In the actual XamComboEditor control, I just use the ItemTemplate to define the content of each item in the popup.
Hi How to se dropdown width different from combobox width
I have tried this but don't work
<DataTemplate>
<StackPanel Orientation="Horizontal" MinWidth="350" MaxWidth="400" Width="Auto">
<TextBlock Text="{Binding Path=Nome}" Margin="4, 0, 0, 0" Width="150"/>
<TextBlock Text="{Binding Path=Mansione}" Margin="4, 0, 0, 0" Width="150"/>
</StackPanel>
</DataTemplate>
thank you very much