.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.95
Released: January 21, 2019
Price: $ 69

downloadorder


Our Customers



Testimonials

I don't think I've ever had a better support experience in regard to any of the 3rd party tools we use.

Tim Stickley

        © 2003 - 2024 ComponentAce  | .net zip component | barcode for .net | delphi zip component | delphi database Apr 19, 2024