|
-
May 22nd, 2001, 08:15 PM
#1
Thread Starter
Addicted Member
Zipping Files
Is there any way to zip and unzip files without the use of a special dll? I have done it with the unzip10.dll, but need to do it without the dll? Is this possible? Thanks for any help!!!!
-
May 22nd, 2001, 08:32 PM
#2
you could Shell pkzip, or WinZip, or CCZip, (or a myriad of others ). Or are you trying to make a Zip utility of your own?
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
-
May 22nd, 2001, 08:39 PM
#3
Hyperactive Member
This worked for me
And in back-ground (invisible to user):
Rem Call Shell(Environ("ComSpec") & "/c pkunzip YourFile.zip -sYourPassword", vbHide)
(no spaces between -s and the password)
YourPassword is optional, off course, in case you used it when zipping the file..
Combat poverty: kill a poor!!
-
May 22nd, 2001, 09:32 PM
#4
Thread Starter
Addicted Member
I need to zip and unzip files behind the scenes of a program and can't have the added bulk of a .dll.
I tried
Call Shell(Environ("ComSpec") & "/c pkunzip C:\trial1.zip
and it told me that the file could not be found despite it being a valid file location. What else can I try??? Thank you all...
-
May 22nd, 2001, 10:07 PM
#5
If you don't want ot use an external DLL, or an external app (which is more trouble than the DLL approach), then you will be limited to writing your own dompression/decompression code inside your app, which to my mind seems like a whole lot of unnecessary work. But if you want to take that path, then the basic algorithm is available on the InfoZip site somwhere.
Why don't you want to have an external DLL (given that you already have a number of external DLL's anyway cos you (I assume) are writingthe app in VB)?
- gaffa
-
May 22nd, 2001, 10:14 PM
#6
Thread Starter
Addicted Member
I really want to create a simple app that is stand-alone (not possible in VB as far as I know). All that it needs to do is:
1) unzip a set of files
2) execute one of these unzipped files (stand-alone freeware app)
3) wait for the user to click a stop button
4) when stop is clicked...stop the running program and zip all files back up
I figured that since I can't creat an app in VB that will run on its own, that I would hope that the user would have the bare-bone control runtimes already installed (from IE, etc)...I knew they wouldn't have unzip10.dll, so I was hoping to embed this functionality into the program.
Anyone have any ideas on how else I could accomplish the four steps that I need?
-
May 22nd, 2001, 10:25 PM
#7
I certainly wouldn't be hedging my bets on the client machines having the correct runtimes. In my experience, that approach works maybe 40% of the time - the other 60% percent fail rate means that you get some very displeased clients.
There are programs out there that will static-link the DLL's into an EXE file, removing the need for support files. I think one is called Crunch, and there's another one I can't remember the name of.
If you're feeling game, you could also control the compilation process instead of letting VB do it (you call c2.exe and then link.exe your self with the appropriate parameters). The link.exe, which is the bit that actualy decides how the program links to DLL's and other files, can be set up to static link. But I'm not sure how to actually achieve this task. I just know it can be done.
- gaffa
-
May 22nd, 2001, 10:43 PM
#8
Thread Starter
Addicted Member
Thank you for your help. I have no experience in C++, but I have access to it at school. For the simple tasks that I need to do, maybe I can create something. You don't happen to know another language like that do you? I just ask to see where some other helpful forums might be...
Thanks again!
-
May 22nd, 2001, 10:57 PM
#9
You might try Delphi. I'm not much chop at Delphi, but it certainly builds standalone EXE files, and I think you have the option to static link dependency files.
- gaffa
-
May 22nd, 2001, 11:06 PM
#10
Thread Starter
Addicted Member
Thank you!!! I will try to find some place that has a version of Delphi...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|