Extracts all of the files from a zip file to a local directory. The zip file must be a standard zip file and cannot be password protected.
Action ID: 5
Action Category:
File Operations
The full path and filename of the zip file to extract from.
The local folder to extract all of the files in the zip archive to.
If checked, the files will maintain their relative paths according to the zip settings when extracted. If unchecked, the files will all be extracted directly to the folder specified in Unzip to folder above, without creating any sub-directories. This option only has an effect if the files in the zip file were added with the preserve path information option enabled in the zip utility used to prepare the zip file.
Value |
Simple Message |
Verbose Message |
0 (OK) |
|
|
1 |
Failed to extract Zip file. |
The specified file was not found. |
2 |
Failed to extract Zip file. |
Error reading Zip directory. |
3 |
Failed to extract Zip file. |
Unable to change local directory. |
4 |
Failed to extract Zip file. |
Extract stage failed. |
5 |
Failed to extract Zip file. |
Unable to create local directory. |
In this example, we'll unzip a file named update.zip, which has already been downloaded to the users temp directory, to a folder called "setup" in the user's temp directory. Once the contents of the zip file have been extracted, they will be available for other actions to use. For example, if update.zip contained an executable named patch.exe, after the executable was extracted from the update.zip file, an Execute File action could be used to launch it.
Note: %TempDir% is a built-in variable.
Zip file name: %TempDir%\update.zip
Unzip to folder: %TempDir%\update
Use internal zip folder names: Unchecked
See Also: Alphabetical List of Actions, Categorical List of Actions, On Error tab