PDA

View Full Version : Batch extract different RAR archives that have same password?


paulescobar
January 1st, 2009, 07:00 PM
I backed up my icon sets in password-protected RAR archives.
Now I'd like to extract them.

Problem is, I didn't create a split-archive.
Instead I created a seperate archive for each set.
Luckily, they all share the same password.

But WinRar keeps asking me for the password, every archive.
That means I have to sit around & monitor the extractions of over 100 archives.

I'd like to input the password once.
Then let the software extract the various archives automatically.

Is this possible in WinRar?
Is this possible in another extraction software?

___


P.S.

Someone suggested I use the WinRar command line features.
Unfortunately, I have no idea how it works. :'(
I keep getting errors with my code.

So if someone can help me, here is my situation...

The OS:
Windows XP

The archives are located at:
C:\Downloads\A.rar
C:\Downloads\B.rar
C:\Downloads\C.rar

The password for each archive is:
iconpass

The extraction location should be:
C:\Icons\

iceni60
January 1st, 2009, 09:37 PM
open a dos prompt and run this -
cd C:\Downloads
C:\Program Files\WinRAR\unrar.exe e -p iconpass *.rar
i haven't got windows, but it might work.

i found this too if that doesn't work -
http://www.respower.com/page_tutorial_unrar

Sully
January 2nd, 2009, 03:39 AM
-{ Quote: "open a dos prompt and run this -
cd C:\Downloads
C:\Program Files\WinRAR\unrar.exe e -p iconpass *.rar
i haven't got windows, but it might work.

i found this too if that doesn't work -
http://www.respower.com/page_tutorial_unrar" }-

Very close for not having windows. Using v3.7 it would be

"C:\Program Files\WinRAR\unrar.exe" e -ad -ppassword *.rar c:\Icons

For v3.7 you must place the password directly after the -p, else it queries you. Also, the addition of -ad is so that each archive is extracted to it's own sub-directory, in case that is needed. Omit if not.

Sul.

paulescobar
January 2nd, 2009, 06:02 AM
Thank you so much iceni60! :D

Your post got me started on the right path.
A couple of things I had to change, as Sully pointed out.

But within half an hour, I figured out how to batch extract/test my archives.

Also, thanks to Sully for sharing that code. :D

You're absolutely right about the password bit.

But I used the "x" command instead of "e"...
Because there were folders within the archive that I wanted to extract.

Again, thanks to you both! :D
I couldn't find a solution to this problem on "google".
Hopefully others will take advantage of this topic.