Home Forums WinForms controls Xceed Grid for WinForms CurrentRow Reply To: CurrentRow

Xceed Support
Post count: 5658

Here is a short snippet of code that shows how to get the Value of a cell of the CurrentRow and how to know the Index of a Row (in this case, the CurrentRow):

string value = ( ( Xceed.Grid.DataRow )gridControl1.CurrentRow ).Cells[ 0 ].Value.ToString();
int rowNumber = gridControl1.DataRows.IndexOf( ( Xceed.Grid.DataRow )gridControl1.CurrentRow );

Imported from legacy forums. Posted by CharlesB (had 515 views)