PDA

Click to See Complete Forum and Search --> : DataGrid value


XboxMan
May 22nd, 2002, 09:18 AM
How Do you do this (VB6)

Me.DataGrid1.Columns(1).Value

In Vb.net to get the current row value.

Cheers

RichardAtherton
May 25th, 2002, 03:51 AM
here's an example:

Dim currow As Integer
currow = DataGrid2.CurrentRowIndex
Label38.Text = DataGrid2.Item(currow, 0)

In this example, the label text is set to the value of the 1st cell in the current selected row, but it could be any column, just chnage the 0 to the column number (which start from 0)