Page 1 of 1

Misspelled procedure name in XLSSheetData5 (v5.20.69)

Posted: Tue Jan 26, 2016 6:19 pm
by KenWhite
There is a typo in XLSSheetData5, in a method name for TXLSWorksheet:

Code: Select all

procedure ClearCell(const ACol, ARow: integer);
procedure CelarCells(const ACol1, ARow1, ACol2, ARow2: integer);   // Should be ClearCells
As this not only hides the method name from Code Insight in the IDE, but makes it impossible to locate without going through the source, is it possible to have this corrected in a future version?

Actually, it turns out that the method doesn't work at all.

Code: Select all

procedure TForm1.Button1Click(Sender: TObject);
var
  StartCol, StartRow, EndCol, EndRow: Integer;
begin
  // XLS is a TXLSReadWriteII5 component placed on  the form at design-time, all properties left at default values.
  XLS[0].FillRandom('A1:D9', 100);

  if RefStrToColRow('A3', StartCol, StartRow) and  RefStrToColRow('D3', EndCol, EndRow) then
    XLS[0].CelarCells(StartCol, StartRow, EndCol, EndRow)
  XLS.SaveToFile('E:\TempData\DummyExcelFile.xlsx');
end;
Is there something I'm doing wrong here?

Re: Misspelled procedure name in XLSSheetData5 (v5.20.69)

Posted: Tue Feb 02, 2016 9:11 am
by larsa
Hello

ClearCell(s) delete cells but keeps any formatting (that is, formatted cells with values are converted to blank cells). The error is that this only works on formatted cells. The rest is not deleted. Will fix this and the wrong name in the next update.

Re: Misspelled procedure name in XLSSheetData5 (v5.20.69)

Posted: Wed Feb 03, 2016 1:36 pm
by KenWhite
Thanks, Lars.