How would I make a row in a datagridview "selected" without clicking on the grid? For example, on form load I want row 5 to be the selected row. CAn this be done?
Printable View
How would I make a row in a datagridview "selected" without clicking on the grid? For example, on form load I want row 5 to be the selected row. CAn this be done?
VB Code:
DataGridNameHere.Rows(4).Selected = True
use 4 because of the 0 based index of the rows collection.
I knew that it would be simple. Thanks.