JN
Jayakumar Natarajan
Syncfusion Team
January 28, 2007 05:17 PM UTC
Hi Andi,
If you have access to CurrentCell, please use this code:
GridCurrentCell cc = Grid.TableControl.CurrentCell;
GridTableCellStyleInfo style = Grid.TableControl.Model[cc.RowIndex, cc.ColIndex] as GridTableCellStyleInfo;
if(style != null)
{
Console.WriteLine("column: {0}", style.TableCellIdentity.Column.Name);
}
With a column index,
int fieldIndex = Grid.TableControl.TableDescriptor.ColIndexToField(colIndex);
Console.WriteLine(Grid.TableDescriptor.Columns[fieldIndex].Name);
Regards,
Jay