Table of Contents

ZipUtil control

Create

Create a ZipUtil control using the CreateZipUtil function of the app object:

var zip = app.CreateZipUtil();

Also you can use it in a function like this:

function unzip(zipfile, extractpath)
{
    var zip = app.CreateZipUtil();
    zip.Open(zipfile);
    var files = zip.List().split(",");
    files.forEach(function (item)
    {
        zip.Extract(item, extractpath+"/"+item);
    });
    zip.Close();
}

Methods

Method Description
ZipUtil.AddFile( name,file )
ZipUtil.AddText( name,text )
ZipUtil.Close()
ZipUtil.Create( file )
ZipUtil.Extract( name,file )
ZipUtil.List( path )
ZipUtil.Open( file )