FG
Franz Gsell
September 20, 2007 11:50 AM UTC
Just a try: would it be correct to do something like this:
int fieldIndex = tableControl.TableDescriptor.ColIndexToField(this.ColIndex);
GridVisibleColumnDescriptor visibleDescriptor = tableControl.TableDescriptor.VisibleColumns[fieldIndex];
GridColumnDescriptor colDescriptor = tableControl.TableDescriptor.Columns[visibleDescriptor.Name];
to get the corresponding GridColumnDescriptor?
The handling of the column indizies is a little bit confusing.
J.
J.Nagarajan
Syncfusion Team
September 20, 2007 11:11 PM UTC
Hi Franz,
The GridColumnDescriptor provides the mapping information to a column of the underlying datasource. All the columns from the datasource are managed by the GridColumnDescriptorCollection that is returned by the GridTableDescriptor. Whereas, the GridVisibleColumnDescriptor refrences the GridColumnDescriptor, but this defines the order of columns shown in the grid from left to right.
What you have tried in earlier update is fine. You can go ahead with this.
Please let me know if you need more information.
Regards,
Nagaraj