943,735 Members | Top Members by Rank

Ad:
Jul 22nd, 2004
0

batch file help - extraction

Expand Post »
Hello everyone. I would like to make a batch file that extracts the contents of MANY .zip files (<name>001-146) to a certain folder, without having to manually extract them. My .bat skills are not good enough to do it and it would be a usuful tool that i currently need. Can someone please post the batch code that will do this.

many thanks in advance.
Similar Threads
Reputation Points: 13
Solved Threads: 0
Posting Whiz in Training
marceta is offline Offline
217 posts
since May 2004
Jul 22nd, 2004
0

Re: batch file help - extraction

Hello,

The older DOS PKUNZIP might work for you. I wonder if WinZip has something like that available too.

I wonder if you could instead of getting a bunch of .ZIP files, if your source could send you ONE zip file with everything inside it.

You cannot just go PKUNZIP *.ZIP as your files would be placed in the working folder and be mingling with your .ZIP files too. That would be bad.

Good luck on this one.
Team Colleague
Reputation Points: 121
Solved Threads: 57
Posting Virtuoso
kc0arf is offline Offline
1,629 posts
since Mar 2004
Jul 22nd, 2004
0

Re: batch file help - extraction

thx for tryin, winzip cant do it and i am NOT prepared to do it myself does anyone know how to do it?
Reputation Points: 13
Solved Threads: 0
Posting Whiz in Training
marceta is offline Offline
217 posts
since May 2004
Jul 22nd, 2004
0

Re: batch file help - extraction

Can you extract them from the command line how you want? If not, the rest of the post won't be very useful.

To get a file listing of all the zip files in a directory, use:

dir *.zip /b > names.txt

your batch file may go something like this (stick with me, I'm used to Linux)
Oh, and one more note: I use binary numbers for temporary directory names just so I can practice binary.

mkdir 00000000
cd 00000000
unzip ../filename.zip
cd ..

mkdir 00000001
cd 00000001
unzip ../filename2.zip
cd ..

and so on...
Last edited by Puckdropper; Jul 22nd, 2004 at 4:03 am. Reason: Clarity
Reputation Points: 23
Solved Threads: 23
Posting Pro in Training
Puckdropper is offline Offline
494 posts
since Jul 2004
Jul 22nd, 2004
0

Re: batch file help - extraction

cool man, thx. Ive got the list of files, now, i cant the extract to work. i have

"unzip /<filename><no.>.zip

but no good. is it something to do with those numbers (i dont really get them)
Reputation Points: 13
Solved Threads: 0
Posting Whiz in Training
marceta is offline Offline
217 posts
since May 2004
Jul 22nd, 2004
0

Re: batch file help - extraction

Hey marceta. Have you considered that some of those zip archives might contain files with the same filename? Extracting all the archives into the one directory as a 'batch' operation might not be the wisest thing to do. You might just end up with some files lost from the exercise
Team Colleague
Reputation Points: 229
Solved Threads: 149
Grandad
Catweazle is offline Offline
3,826 posts
since Mar 2004
Jul 22nd, 2004
0

Re: batch file help - extraction

well it took about 30mins, but i did it all by hand, i guess i should feel proud, but i dont
Reputation Points: 13
Solved Threads: 0
Posting Whiz in Training
marceta is offline Offline
217 posts
since May 2004
Jul 22nd, 2004
0

Re: batch file help - extraction

Go and celebrate by having a nice cold can of root beer. I find Barqs is best Ice Cold. ;-)
Reputation Points: 23
Solved Threads: 23
Posting Pro in Training
Puckdropper is offline Offline
494 posts
since Jul 2004
Jul 22nd, 2004
0

Re: batch file help - extraction

WINRAR Can do batches.
Reputation Points: 17
Solved Threads: 6
Junior Poster in Training
JR85023 is offline Offline
86 posts
since May 2004

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Windows NT / 2000 / XP Forum Timeline: XP reinstall from English to Italian version
Next Thread in Windows NT / 2000 / XP Forum Timeline: cannot find shell.dll





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC