.NET Zip component, Delphi Zip component, Barcode .NET, BDE Replacement and other .NET and Delphi components from ComponentAce
Products Download Order Contact us

Search
 

Delphi/C++ Components
.NET Components
ActiveX Controls
Kylix Components

Download

Download
Download Commercial
Trial Limitations

Support

Submit Request
Support Options

Order

Purchase
Competitive Upgrade
Premium Support
Sales Policy
Upgrade Policy
License Types

Info

News
Mailing List
Articles
Testimonials



About Us
Partners
Links
Contact Us
Link to Us





Home > Delphi/C++ Components > ZipForge > ZIP and Progress Indication in Delphi

Delphi Zip Component ZipForge

Overview | Features | Requirements | Testimonials | Manual | Code Samples | Download | Order
ZIP and Progress Indication in Delphi
This sample shows how to implement progress indication in ZipForge.

Download ZipForge | Learn More | All Delphi samples
unit MainFrm;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls, ComCtrls, ZipForge;

type
  TMainForm = class(TForm)
    Archiver: TZipForge;
    pbProgress: TProgressBar;
    btnExtract: TButton;
    lblFile: TLabel;
    procedure ArchiverOverallProgress(Sender: TObject; Progress: Double;
      Operation: TZFProcessOperation; ProgressPhase: TZFProgressPhase;
      var Cancel: Boolean);
    procedure ArchiverFileProgress(Sender: TObject; FileName: WideString;
      Progress: Double; Operation: TZFProcessOperation;
      ProgressPhase: TZFProgressPhase; var Cancel: Boolean);
    procedure btnExtractClick(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  MainForm: TMainForm;

implementation

{$R *.dfm}

procedure TMainForm.ArchiverOverallProgress(Sender: TObject;
  Progress: Double; Operation: TZFProcessOperation;
  ProgressPhase: TZFProgressPhase; var Cancel: Boolean);
begin
  pbProgress.Position := Trunc(Progress);
  Application.ProcessMessages;
end;

procedure TMainForm.ArchiverFileProgress(Sender: TObject;
  FileName: WideString; Progress: Double; Operation: TZFProcessOperation;
  ProgressPhase: TZFProgressPhase; var Cancel: Boolean);
begin
  lblFile.Caption := 'Extracting: ' + FileName;
  Application.ProcessMessages;
end;

procedure TMainForm.btnExtractClick(Sender: TObject);
begin
  Archiver.FileName := 'c:\test.zip';
  Archiver.OpenArchive;
  Archiver.BaseDir := 'c:\temp';
  Archiver.ExtractFiles('*.*');
  Archiver.CloseArchive;
end;

end.



Download ZipForge | Learn More | All Delphi samples


Product Info


Current version: 6.91
Released: June 15, 2017
Price: $ 69

downloadorder


Our Customers



Testimonials

The other people in the office didn't believe me when I said that all I had to do was document the problem and you would probably give me a fix overnight. Unbelievable! Keep up the great work. I hope you guys all make a fortune out of this product because it is truly fantastic and the support is the best I have ever encountered.

Mark Kefford

        © 2003 - 2018 ComponentAce  | .net zip component | barcode for .net | delphi zip component | delphi database Jul 18, 2018