在WPF中,我如何把一个DataGrid放在ComboBox里以显示多列?像以下代码似乎没有任何作用:
<ComboBox>
<ItemsPanelTemplate>
<DataGrid>
<DataGrid.Columns>
<DataGridTextColumn Binding="{Binding customerName}" />
<DataGridTextColumn Binding="{Binding billingAddress}" />
</DataGrid.Columns>
</DataGrid>
</ItemsPanelTemplate>
</ComboBox>
MyCustomer
对象,以便确定这是否可行,或者你有关于你正在尝试创建的内容的图片吗?也许我能提供帮助。 - sa_ddam213Class CustomerBO Public Property customerID As String Public Property customerName As String Public Property billingAddress As String Public Property billingCity As String ... End Class
- dotNET