Column is derived from DataObject which is derived from DataObjectBase, which has a method GetIndex();
The following code shows how,
void LT_set_cell(string strVal, string strColName = "B", int nRow = 3)
{
Worksheet wks = Project.ActiveLayer();
Column cc = wks.Columns(strColName);
if(cc)
{
int nCol = cc.GetIndex();
wks.SetCell(nRow + 1, nCol, strVal); // use LT indexing in nRow
}
}
CP