Zip Files with VBScript and WinZip

A couple of months ago I posted an entry about zipping and unzipping files with 7zip and VBScript. The script works well and I use it quite frequently and I definitely recommend it over WinZip if you have a choice.

I ran into a situation for a client where they needed a scripting solution but didn’t want to use open source software because of a lack of support options and reluctance to move to an open source software model. Well in this situation I had to make due with what I had and I whipped up a script to zip files using WinZip. Sorry no UnZip yet, if someone really needs it feel free to send me an email or leave a comment.

This particular function relies on WZZIP.exe which is the command line equivalent of WinZip’s gui interface. There are lots of command line switches you could add in if you desired other behavior. For example you can select to delete the files after they have been successfully compressed or select different levels of compression if you desired speed over minimum file size.

Anyway here is the function to zip files using WinZip instead of 7Zip.


Leave a Comment