Einzelnen Beitrag anzeigen

tekkyeah

Registriert seit: 24. Nov 2003
27 Beiträge
 
Delphi 2006 Professional
 
#6

AW: Excel-Export, RefToCell, Spalten>26

  Alt 27. Jan 2012, 18:58
Delphi-Quellcode:
  if col < 26 then
  begin
    Result := Chr(Ord('A') + Col - 1) + IntToStr(Row);
  end else
  begin
    Result := Chr((Col DIV 26) - 1 + Ord('A')) +
              Chr((Col MOD 26) + Ord('A')) + IntToStr(Row);
  end;
Holger
  Mit Zitat antworten Zitat