Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions xml/System.Windows.Controls/DataGrid.xml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
You can use the <xref:System.Windows.Controls.DataGrid.Columns%2A> collection to programmatically add, insert, remove, and change any columns in the control at run time. Check the <xref:System.Windows.Controls.DataGridColumn.IsAutoGenerated%2A> property to determine whether a column is auto generated or user defined. Auto-generated columns will be automatically added, removed, or regenerated when the <xref:System.Windows.Controls.ItemsControl.ItemsSource%2A> changes.

## Selection
By default, the entire row is selected when a user clicks a cell in a <xref:System.Windows.Controls.DataGrid>, and a user can select multiple rows. You can set the <xref:System.Windows.Controls.DataGrid.SelectionMode%2A> property to specify whether a user can select cells, full rows, or both. Set the <xref:System.Windows.Controls.DataGrid.SelectionUnit%2A> property to specify whether multiple rows or cells can be selected, or only single rows or cells.
By default, the entire row is selected when a user clicks a cell in a <xref:System.Windows.Controls.DataGrid>, and a user can select multiple rows. You can set the <xref:System.Windows.Controls.DataGrid.SelectionUnit%2A> property to specify whether a user can select cells, full rows, or both. Set the <xref:System.Windows.Controls.DataGrid.SelectionMode%2A> property to specify whether multiple rows or cells can be selected, or only single rows or cells.

You can get information about the cells that are selected from the <xref:System.Windows.Controls.DataGrid.SelectedCells%2A> property. You can get information about cells for which selection has changed in the <xref:System.Windows.Controls.SelectedCellsChangedEventArgs> of the <xref:System.Windows.Controls.DataGrid.SelectedCellsChanged> event. Call the <xref:System.Windows.Controls.DataGrid.SelectAllCells%2A> or <xref:System.Windows.Controls.DataGrid.UnselectAllCells%2A> methods to programmatically select or unselect all cells. For more information, see [Default Keyboard and Mouse Behavior in the DataGrid Control](~/docs/framework/wpf/controls/default-keyboard-and-mouse-behavior-in-the-datagrid-control.md).

Expand Down Expand Up @@ -5879,4 +5879,4 @@
</Docs>
</Member>
</Members>
</Type>
</Type>