Link to home
Start Free TrialLog in
Avatar of SwiftStephen
SwiftStephen

asked on

ZIP or Compress from a command line using RunDll32.exe zipfldr.dll

I have been trying to figure out the Syntax for creating ZIP files from a command line without 3rd party software, using the RunDll32.exe zipfldr.dll,RouteTheCall (filename), but it doesn't really seem to be working.  I'm pretty sure this is close to the real Syntax, but I could not locate anything in the registry pionting any further.

So, I have it so far from the C:\> RunDll32.exe zipfldr.dll,RouteTheCall (filename), ALMOST works.

If you have any suggestions, please let me know.
Avatar of Shane Russell
Shane Russell
Flag of United Kingdom of Great Britain and Northern Ireland image

I found this :

rundll32.exe zipfldr.dll,RouteTheCall %L

With regards to verify settings on this page :

http://www.kellys-korner-xp.com/xp_w.htm

It is at the bottom of that page. I also found this :

http://www.pcreview.co.uk/forums/thread-91217.php

I am guessing if you use the %L switch that should make it worth because that is the long file name and %1 lets windows decide whether to use long or short depending on the exe according to the above URL.
So from that I would say something like so :

C:\> RunDll32.exe zipfldr.dll,RouteTheCall %L(filename)

OR

C:\> RunDll32.exe zipfldr.dll,RouteTheCall %1(filename)
Found this :

http://www.dx21.com/SCRIPTING/RUNDLL32/VIEWITEM.ASP?OID=199&CMD=P-A

Saying that is used to open a zip file not to make or create a zip file.
As per fatal exceptions suggest in that PAQ, you can use the compact command  :)

With regards to 3rd party zip apps I would suggest you use 7 zip if you do go for a 3rd party tool.

http://www.7-zip.org/
Avatar of SwiftStephen
SwiftStephen

ASKER

I have found that "RunDll32 zipfldr.dll,RouteTheCall (filename.zip)" will open a ZIP file into a folder view, but I'm trying to go the other way around.  I would like to take a folder, and make it a ZIP file from a command line without any 3rd party program.  I have played with the %L and the %1, and found those are to be replaced the filename.zip to open.  I'm sure there is something other then "RouteTheCall" to create the ZIP.  I will keep searching the web, and the registry for any clues, and thanks everyone so far for the links, and suggestions.  

Still searching  . . .
Please no more posts on the Compress command.  THAT DOES NOT CREATE ZIP files. If it does, please forgive me and let me know how to create a ZIP file from the compress command.

Thanks.
Sorry not trying to be rude, but trying to create ZIP files from command line without 3rd party software.  "gecko_au2003" you have been trying hard, so thank you for your attempts.  You appear to have had the same result as I in previous links.  I think we might have to use a hidden switch on the explorer.exe
ASKER CERTIFIED SOLUTION
Avatar of Shane Russell
Shane Russell
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
If you dont think it works then give it a go, that would be the best bet to testing it out :

There are examples of how to use and a useage table that shows you the switches ( which you could just as easily get by typing :

compact /? in a command prompt.

Give the example(s) at the bottom of this Page which I also posted earlier a try and post back with your findings / results of what happened.

http://www.computerhope.com/compact.htm

Make a new folder on the C: drive , call it Test if you will and in there make some dummy files ie some text files, then go to the command line and use cd to navigate to the test folder on the C drive and use the compact command as per the above URL and see what happens.
I know its an old post but just FYI
Compact /c filename*.* in my case compacted the files individually instead of compacting them into a single file as a ZIP would. so here it is 2010 and you still cant do this.