DataGridComboBoxColumn.GenerateEditingElement(DataGridCell, Object) 方法

定义

获取一个组合框控件,该控件绑定到列的 SelectedItemBindingSelectedValueBindingTextBinding 值。Gets a combo box control that is bound to the column's SelectedItemBinding, SelectedValueBinding, and TextBinding values.

protected:
 override System::Windows::FrameworkElement ^ GenerateEditingElement(System::Windows::Controls::DataGridCell ^ cell, System::Object ^ dataItem);
protected override System.Windows.FrameworkElement GenerateEditingElement (System.Windows.Controls.DataGridCell cell, object dataItem);
override this.GenerateEditingElement : System.Windows.Controls.DataGridCell * obj -> System.Windows.FrameworkElement
Protected Overrides Function GenerateEditingElement (cell As DataGridCell, dataItem As Object) As FrameworkElement

参数

cell
DataGridCell

将包含所生成元素的单元格。The cell that will contain the generated element.

dataItem
Object

由包含预期单元格的行表示的数据项。The data item represented by the row that contains the intended cell.

返回

FrameworkElement

一个新的组合框控件,该控件绑定到列的 SelectedItemBindingSelectedValueBindingTextBinding 值。A new combo box control that is bound to the column's SelectedItemBinding, SelectedValueBinding, and TextBinding values.

适用于