Hi,
I can't figure out how to get column names by its index. Like 1 => "A".
Found nothing in manual nor in the examples / sources.
thx
adrian
(adrian)
2
Hi,
which will do what you want, but normally it is simpler to just create a TCellAddress record and use it to convert. For example:
//Convert from B5 to 5,2
a := TCellAddress.Create('B5');
xls.GetCellValue(a.Row, a.Col);
or
//Convert from 5,2 to B5:
a := TCellAddress.Create(5, 2);
DoSomething(a.CellRef); //CellRef has the text "B5"
Those examples were taken from:
Adrian,
Thank you. "EncodeColumn" is the winner as I need column names and not cell references.
It's not too intuitive but now as I have it, it doesn't matter anymore.
Thx for the prompt reply!