【发布时间】:2018-12-26 16:38:06
【问题描述】:
我正在尝试将组合框绑定到字典。 “阶段”是 ProjectPlans 类中的字典
public Dictionary<decimal?, string> Phases { get; set; }
组合框不显示值,而是只显示单词“(集合)”,没有下拉箭头。我错过了什么?
<c1:C1DataGrid ItemsSource="{Binding ProjectPlans}" IsReadOnly="True" RowDetailsVisibilityMode="VisibleWhenSelected">
<c1:C1DataGrid.Columns>
<c1:DataGridBoundColumn Header="ID" Binding="{Binding ProjectId}" />
<c1:DataGridComboBoxColumn Header="PHASE" Binding="{ Binding Phases}" DisplayMemberPath="Value" SelectedValuePath="Key"/>
【问题讨论】: