zip_compress()

Read(2399) Label: zip, compression mode & level,

Description:
Set compression mode and level for a would-be zip file.

Syntax:
zip_compress(
zip,mode,level)

Note:

This external library function (See External Library Guide) sets mode and level for compresing a file to get various compression ratio.

Parameter:

zip

A zip file object.

mode 

Compression mode

0: Won’t compress

1: Standard compression

2: AES_ENC mode compression

Other values: Standard compression.

 

level

Compression level:

1: DEFLATE_LEVEL_FASTEST

2: DEFLATE_LEVEL_FAST

3: DEFLATE_LEVEL_NORMAL

4: DEFLATE_LEVEL_MAXIMUM

5: DEFLATE_LEVEL_ULTRA

Other values: DEFLATE_LEVEL_NORMAL.

Return value
Boolean value

Example:

 

A

 

1

=zip_open("D:/emp.zip")

Open a zip file.

2

=zip_encrypt(A1,1,3)

Standard encryption.

3

>zip_close(A1)

Open a zip file.