Delphi ActiveX Requires Chilkat v11.0.0+
Delphi ActiveX
Transition from Zip.FirstEntry to Zip.EntryAt
Provides instructions for replacing deprecated FirstEntry method calls with EntryAt.Chilkat Delphi ActiveX Downloads
var
success: Integer;
zip: TChilkatZip;
entryObj: IChilkatZipEntry;
ze: TChilkatZipEntry;
begin
success := 0;
zip := TChilkatZip.Create(Self);
// ...
// ...
// ------------------------------------------------------------------------
// The FirstEntry method is deprecated:
entryObj := zip.FirstEntry();
if (zip.LastMethodSuccess = 0) then
begin
Memo1.Lines.Add(zip.LastErrorText);
Exit;
end;
// ...
// ...
// ------------------------------------------------------------------------
// Do the equivalent using EntryAt.
// Your application creates a new, empty ZipEntry object which is passed
// in the last argument and filled upon success.
// The 1st entry is at index 0.
ze := TChilkatZipEntry.Create(Self);
success := zip.EntryAt(0,ze.ControlInterface);
if (success = 0) then
begin
Memo1.Lines.Add(zip.LastErrorText);
Exit;
end;