DataGrid Events
Events
ActualThemeVariantChanged | Raised when the theme variant is changed on the element or an ancestor of the element. (Inherited from StyledElement) |
AttachedToLogicalTree | Raised when the styled element is attached to a rooted logical tree. (Inherited from StyledElement) |
AttachedToVisualTree | Raised when the control is attached to a rooted visual tree. (Inherited from Visual) |
AutoGeneratingColumn | Occurs one time for each public, non-static property in the bound data type when the ItemsSource property is changed and the AutoGenerateColumns property is true. |
BeginningEdit | Occurs before a cell or row enters editing mode. |
CellEditEnded | Occurs after cell editing has ended. |
CellEditEnding | Occurs immediately before cell editing has ended. |
CellPointerPressed | Occurs when cell is mouse-pressed. |
ColumnDisplayIndexChanged | Occurs when the DisplayIndex property of a column changes. |
ColumnReordered | Raised when column reordering ends, to allow subscribers to clean up. |
ColumnReordering | Raised when starting a column reordering action. Subscribers to this event can set tooltip and caret UIElements, constrain tooltip position, indicate that a preview should be shown, or cancel reordering. |
ContextRequested | Occurs when the user has completed a context input gesture, such as a right-click. (Inherited from Control) |
CopyingRowClipboardContent | This event is raised by OnCopyingRowClipboardContent method after the default row content is prepared. Event listeners can modify or add to the row clipboard content. |
CurrentCellChanged | Occurs when a different cell becomes the current cell. |
DataContextChanged | Occurs when the DataContext property changes. (Inherited from StyledElement) |
DetachedFromLogicalTree | Raised when the styled element is detached from a rooted logical tree. (Inherited from StyledElement) |
DetachedFromVisualTree | Raised when the control is detached from a rooted visual tree. (Inherited from Visual) |
DoubleTapped | Occurs when a double-tap gesture occurs on the control. (Inherited from InputElement) |
EffectiveViewportChanged | Occurs when the element's effective viewport changes. (Inherited from Layoutable) |
GotFocus | Occurs when the control receives focus. (Inherited from InputElement) |
Holding | Occurs when a hold gesture occurs on the control. (Inherited from InputElement) |
HorizontalScroll | |
Initialized | Occurs when the styled element has finished initialization. (Inherited from StyledElement) |
KeyDown | Occurs when a key is pressed while the control has focus. (Inherited from InputElement) |
KeyUp | Occurs when a key is released while the control has focus. (Inherited from InputElement) |
LayoutUpdated | Occurs when a layout pass completes for the control. (Inherited from Layoutable) |
Loaded | Occurs when the control has been fully constructed in the visual tree and both layout and render are complete. (Inherited from Control) |
LoadingRow | Occurs after a DataGridRow is instantiated, so that you can customize it before it is used. |
LoadingRowDetails | Occurs when a new row details template is applied to a row, so that you can customize the details section before it is used. |
LoadingRowGroup | Occurs before a DataGridRowGroupHeader header is used. |
LostFocus | Occurs when the control loses focus. (Inherited from InputElement) |
PointerCaptureLost | Occurs when the control or its child control loses the pointer capture for any reason, event will not be triggered for a parent control if capture was transferred to another child of that parent control (Inherited from InputElement) |
PointerEntered | Occurs when the pointer enters the control. (Inherited from InputElement) |
PointerExited | Occurs when the pointer leaves the control. (Inherited from InputElement) |
PointerMoved | Occurs when the pointer moves over the control. (Inherited from InputElement) |
PointerPressed | Occurs when the pointer is pressed over the control. (Inherited from InputElement) |
PointerReleased | Occurs when the pointer is released over the control. (Inherited from InputElement) |
PointerWheelChanged | Occurs when the mouse is scrolled over the control. (Inherited from InputElement) |
PreparingCellForEdit | Occurs when a cell in a DataGridTemplateColumn enters editing mode. |
PropertyChanged | Raised when a AvaloniaProperty value changes on this object. (Inherited from AvaloniaObject) |
ResourcesChanged | Occurs when a resource in this styled element or a parent styled element has changed. (Inherited from StyledElement) |
RowDetailsVisibilityChanged | Occurs when the RowDetailsVisibilityMode property value changes. |
RowEditEnded | Occurs when the row has been successfully committed or cancelled. |
RowEditEnding | Occurs immediately before the row has been successfully committed or cancelled. |
SelectionChanged | Occurs when the SelectedItem or SelectedItems property value changes. |
SizeChanged | Occurs when the bounds (actual size) of the control have changed. (Inherited from Control) |
Sorting | Occurs when the DataGridColumn sorting request is triggered. |
Tapped | Occurs when a tap gesture occurs on the control. (Inherited from InputElement) |
TemplateApplied | Raised when the control's template is applied. (Inherited from TemplatedControl) |
TextInput | Occurs when a user typed some text while the control has focus. (Inherited from InputElement) |
TextInputMethodClientRequested | Occurs when an input element gains input focus and input method is looking for the corresponding client (Inherited from InputElement) |
Unloaded | Occurs when the control is removed from the visual tree. (Inherited from Control) |
UnloadingRow | Occurs when a DataGridRow object becomes available for reuse. |
UnloadingRowDetails | Occurs when a row details element becomes available for reuse. |
UnloadingRowGroup | Occurs when the DataGridRowGroupHeader is available for reuse. |
VerticalScroll |