DataGridView::ClearSelection Method
.NET Framework (current version)
Cancels the selection of currently selected cells.
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
| Name | Description | |
|---|---|---|
![]() | ClearSelection() | Clears the current selection by unselecting all selected cells. |
![]() | ClearSelection(Int32, Int32, Boolean) | Cancels the selection of all currently selected cells except the one indicated, optionally ensuring that the indicated cell is selected. |
Show:

