Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

datagrid select row

Status
Not open for further replies.

luisve

Programmer
Jun 24, 2005
29
US
hi i am using the following code to select all the row in a datagrid when the user changes the current row using the keyboard, this works but the currect cell displays the cursor keyboard cursor(|) how can i avoid this and select all the row in the same color and witout the cursor?

Private Sub DataGrid1_CurrentCellChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles DataGrid1.CurrentCellChanged
Dim pt = DataGrid1.CurrentCell.RowNumber
DataGrid1.CurrentCell = New DataGridCell(pt, DataGrid1.CurrentCell.ColumnNumber)
DataGrid1.Select(pt)
end sub
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top