Can you help? GCC cell values from clicked row

Hi,
I want to extract the values from a row and drop selecte ones into text boxes. So far I can only see

Element el = table.DisplayElements
this.textBoxExt1.Text = el.GetRecord().ToString();

this give me all the data values - I want to get the individual cells in the data row.


Thanks,

3 Replies

AD Administrator Syncfusion Team January 31, 2007 12:34 AM UTC

To retrieve a particular field in a record, you can use

object o = el.GetRecord().GetValue("fieldname");


AD Administrator Syncfusion Team January 31, 2007 02:17 AM UTC

Thanks Clay, that works. Is there a way to do it with the index of the cell rather that the name? Or by looping through the columns, like in Excel VBA?

Dimitri

>To retrieve a particular field in a record, you can use

object o = el.GetRecord().GetValue("fieldname");


AD Administrator Syncfusion Team January 31, 2007 11:57 AM UTC

Given a column index, you can get the field and then get the value using:

int field = this.gridGroupingControl1.TableDescriptor.ColIndexToField(colIndex);
el.GetRecord().GetValue(this.gridGroupingControl1.TableDescriptor.Fields[field]);

Loader.
Up arrow icon