Highlights

Saturday, June 22, 2013

SOLVED! Zipping Multiple Folders Into Separate Zip Files

A friend has a special need to compress many folders into separate zip files. Normally, in Windows Explorer, the output will be ONLY ONE zip file. However, the question is whether a simple solution is around.

Solutions:
There are software tools like WinRAR, which can do it. Even so, the default setting does not allow it and you need to check an option for that. Also, WinRAR is not really free.

After research for a while, here's a simple solution, which is FREE!

What you need is...

(1) Download and install a free copy of 7-ziphttp://www.7-zip.org/

  • I love it as an open source, free yet powerful zip tool


(2) Make a batch file with this command line:

for /d %%X in (*) do "c:\Program Files\7-Zip\7z.exe" a "%%X" "%%X\" -mx=5 –tzip
  • it will do a Normal compress (-mx5) in TZIP format (-tzip), default file extension in .ZIP

(3) Put the batch file in the same folder with the folders you want to zip, execute it

For those who may be interested to know more, of course 7-zip's official website has excellent materials. Also, you may check these websites as well.

Reference: