Android Question Compressing a file with password

khwarizmi

Active Member
Licensed User
Longtime User
Hi all

I want to compress a file with a password. I know that ArchiverPlusZip does this task through:
B4X: Copy
Dim zip As ArchiverPlusZip
zip.EncryptZipWithString(.........)
zip.AddFileToZip(xui.DefaultFolder,"aaa.txt","ar")
but parameters are not clear to me.

thanks in advance
 
Solution
You did NOT understand the system, rigth? :D

The 1st Parameter is ONE of the ZIP_ENC_* Constants.
ZIP_ENC_METHOD_AES, ZIP_ENC_METHOD_STANDARD or ZIP_ENC_NO_ENCRYPTION
but parameters are not clear to me.
Look at the comments for them

Snap3.jpg


So for the first parameter they are
Snap4.jpg


Same applies to the others....

What exactly is the question now?
 
Upvote 0
B4X: Copy
Dim ax As ArchiverPlusZip
    ax.EncryptZipWithString(ax.ZIP_AES_STRENGTH_128, ax.ZIP_AES_STRENGTH_256, "123444")
 
Upvote 0
Back
Top