PDA

View Full Version : Zip password



Lazerpower
07-08-2002, 01:43 PM
Hi all! 4.0..........Awesome!
Question, If I set a password to extract a zip file, when should I be prompted to enter it? It keeps extracting the zip file without asking for the password. Otherwise, so far so good.

Ted
07-08-2002, 01:47 PM
You'll want to use something like a Dialog.GetInformation action to show a dialog that asks for the password. Store the result in a variable and that's what you pass in to the ZipFile.Extract action as the password.


Get password
If canceled, return to page
If entered, check password and unzip if correct
If incorrect, show msgbox with choice to try again or cancel.
If try again, return to Get password
If canceled, return to page

There are a bunch of other ways of doing it as well, such as using an EditBox object, reading from a text file etc etc.