ADAdministrator Syncfusion Team April 19, 2005 09:56 AM
To get the rowindex in the grid, you need to look up the corresponding Record, rec, using grid.Table.DisplayElements.IndexOf(rec).
To actually get the record you need, you have some options depending upon what you know. If you already know the position of the datarow in the DataTable, you can get the record using
Record rec = this.gridGroupingControl1.Table.UnsortedRecords[position];
If you have a primary key for your datatable, you can use
int i = this.gridGroupingControl1.Table.PrimaryKeySortedRecords.IndexOf("keyvalue");
Record rec = this.gridGroupingControl1.Table.FilteredRecords[i];
Again, once you have the record, you can use grid.Table.DisplayElements.IndexOf to get the index.