How can I programatically make a row in a DataGridView selected?
"Rows" is a property of the DataGridView that returns all the rows as a collection. For a particular Row, you can set the .Selected property to True (or False) to select (or unselect) that Row.
For example,
dataGridView1.Rows(index).Selected = True
here,
index you have to mention any value like 1,2,3
"Rows" is a property of the DataGridView that returns all the rows as a collection. For a particular Row, you can set the .Selected property to True (or False) to select (or unselect) that Row.
For example,
dataGridView1.Rows(index).Selected = True
here,
index you have to mention any value like 1,2,3
No comments:
Post a Comment