草庐IT

DataGridComboxBox

全部标签

c# - WPF 数据网格 : DataGridComboxBox ItemsSource Binding to a Collection of Collections

情况:我在XAML中创建了一个DataGrid,并且ItemsSource绑定(bind)到包含属性的特定类的ObservableCollection。然后在C#中,我创建了一个DataGridTextColumn和一个DataGridComboBoxColumn,并将它们绑定(bind)到ObservableCollection中对象的属性。我可以将DataGridComboBoxColumn绑定(bind)到一个简单的Collection,但我想要做的是将它绑定(bind)到一个字符串集合的集合,这样对于每一行,DataGrid中的ComboBox都有一个不同的字符串集合。我没有这