DataGridComboBoxColumn Class

Definition

Represents a DataGrid column that hosts textual content in its cells. In edit mode data can be changed to a value from a collection hosted in a ComboBox.

[Windows.UI.Xaml.StyleTypedProperty(Property="ElementStyle", StyleTargetType=typeof(Windows.UI.Xaml.Controls.TextBlock))]
[Windows.UI.Xaml.StyleTypedProperty(Property="EditingElementStyle", StyleTargetType=typeof(Windows.UI.Xaml.Controls.ComboBox))]
public class DataGridComboBoxColumn : Microsoft.Toolkit.Uwp.UI.Controls.DataGridBoundColumn
[<Windows.UI.Xaml.StyleTypedProperty(Property="ElementStyle", StyleTargetType=typeof(Windows.UI.Xaml.Controls.TextBlock))>]
[<Windows.UI.Xaml.StyleTypedProperty(Property="EditingElementStyle", StyleTargetType=typeof(Windows.UI.Xaml.Controls.ComboBox))>]
type DataGridComboBoxColumn = class
    inherit DataGridBoundColumn
Public Class DataGridComboBoxColumn
Inherits DataGridBoundColumn
Inheritance
Windows.UI.Xaml.DependencyObject
DataGridComboBoxColumn
Attributes
Windows.UI.Xaml.StyleTypedPropertyAttribute

Constructors

DataGridComboBoxColumn()

Fields

DisplayMemberPathProperty

Identifies the DisplayMemberPath dependency property.

FontFamilyProperty

Identifies the FontFamily dependency property.

ItemsSourceProperty

Identifies the ItemsSource dependency property.

Properties

ActualWidth

Gets the actual visible width after Width, MinWidth, and MaxWidth setting at the Column level and DataGrid level have been taken into account.

(Inherited from DataGridColumn)
Binding

Gets or sets the binding that associates the column with a property in the data source.

(Inherited from DataGridBoundColumn)
CanUserReorder

Gets or sets a value indicating whether the user can change the column display position by dragging the column header.

(Inherited from DataGridColumn)
CanUserResize

Gets or sets a value indicating whether the user can adjust the column width using the mouse.

(Inherited from DataGridColumn)
CanUserSort

Gets or sets a value indicating whether the user can sort the column by clicking the column header.

(Inherited from DataGridColumn)
CellStyle

Gets or sets the style that is used when rendering cells in the column.

(Inherited from DataGridColumn)
ClipboardContentBinding

Gets or sets the binding that will be used to get or set cell content for the clipboard. If the base ClipboardContentBinding is not explicitly set, this will return the value of Binding.

(Inherited from DataGridBoundColumn)
DisplayIndex

Gets or sets the display position of the column relative to the other columns in the DataGrid.

(Inherited from DataGridColumn)
DisplayMemberPath

Gets or sets the name or path of the property that is displayed in the ComboBox.

DragIndicatorStyle

Gets or sets the style for the drag indicator.

(Inherited from DataGridColumn)
EditingElementStyle

Gets or sets the style that is used when rendering the element that the column displays for a cell in editing mode.

(Inherited from DataGridBoundColumn)
ElementStyle

Gets or sets the style that is used when rendering the element that the column displays for a cell that is not in editing mode.

(Inherited from DataGridBoundColumn)
FontFamily

Gets or sets the font name.

FontSize

Gets or sets the font size.

FontStyle

Gets or sets the font style.

FontWeight

Gets or sets the font weight or thickness.

Foreground

Gets or sets a brush that describes the foreground of the column cells.

Header

Gets or sets the header object.

(Inherited from DataGridColumn)
HeaderStyle

Gets or sets the style for the header.

(Inherited from DataGridColumn)
IsAutoGenerated

Gets a value indicating whether this column is autoGenerated.

(Inherited from DataGridColumn)
IsFrozen

Gets a value indicating whether this column is frozen.

(Inherited from DataGridColumn)
IsReadOnly

Gets or sets a value indicating whether this column is read-only.

(Inherited from DataGridColumn)
ItemsSource

Gets or sets a collection that is used to generate the content of the ComboBox while in editing mode.

MaxWidth

Gets or sets the column's maximum width.

(Inherited from DataGridColumn)
MinWidth

Gets or sets the column's minimum width.

(Inherited from DataGridColumn)
SortDirection

Gets or sets the column's sort direction. Null indicates no sorting.

(Inherited from DataGridColumn)
Tag

Gets or sets an object associated with this column.

(Inherited from DataGridColumn)
Visibility

Gets or sets the column's visibility.

(Inherited from DataGridColumn)
Width

Gets or sets the column's width.

(Inherited from DataGridColumn)

Methods

CancelCellEdit(FrameworkElement, Object)

Causes the column cell being edited to revert to the specified value.

GenerateEditingElement(DataGridCell, Object)

Gets a Windows.UI.Xaml.Controls.ComboBox control that is bound to the column's ItemsSource collection.

GenerateElement(DataGridCell, Object)

Gets a read-only Windows.UI.Xaml.Controls.TextBlock element that is bound to the column's Binding property value.

GetCellContent(DataGridRow)

Returns the column's content for the provided row.

(Inherited from DataGridColumn)
GetCellContent(Object)

Returns the column's content for the provided row dataItem.

(Inherited from DataGridColumn)
NotifyPropertyChanged(String)

Called by a specific column type when one of its properties changed, and its current cells need to be updated.

(Inherited from DataGridColumn)
PrepareCellForEdit(FrameworkElement, RoutedEventArgs)

Called when the cell in the column enters editing mode.

RefreshCellContent(FrameworkElement, Brush, String)

Called by the DataGrid control when this column asks for its elements to be updated, because a property changed.

RefreshForeground(FrameworkElement, Brush)

Called when the computed foreground of a row changed.

Applies to