Quantcast
Channel: VBForums
Viewing all articles
Browse latest Browse all 42329

[RESOLVED] DataGridView_CellMouseDown

$
0
0
In DataGridView, I want entire row (entire cells) to be selected when one cell is selected.

I'm using this piece of code to acheive this.
Code:

        Dim i As Integer
        For i = 0 To empDataGridView.ColumnCount - 1
            empDataGridView.Rows(e.RowIndex).Cells(i).Selected = True
        Next

Above code works well in _CellMouseUp or _CellClick but not in _CellMouseDown.

Thanks. :)

Viewing all articles
Browse latest Browse all 42329

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>