Connecting Tech Pros Worldwide Help | Site Map

The best VB6 solution for ZIP / UNZIP

dima69's Avatar
Expert
 
Join Date: Sep 2006
Location: Israel
Posts: 181
#1: Jun 18 '07
I'm looking for the solution to Zip / Unzip files in VB6 / VBA.
I've searched the web and found several solutions (zlib.dll, Info-Zip, DynaZip, PKZip, ...). The question is which one is the best ?
My considerations are:
1. The solution must be simple, general and robust (be able to unzip all standard zip files, run on all Win platforms).
2. The solution must be based on standard DLL (not OCX, not command-prompt EXE)
3. No extra features required (password protection, multiple volumes, SFX)
Member
 
Join Date: Mar 2007
Posts: 50
#2: Jun 18 '07

re: The best VB6 solution for ZIP / UNZIP


Quote:

Originally Posted by dima69

I'm looking for the solution to Zip / Unzip files in VB6 / VBA.
I've searched the web and found several solutions (zlib.dll, Info-Zip, DynaZip, PKZip, ...). The question is which one is the best ?
My considerations are:
1. The solution must be simple, general and robust (be able to unzip all standard zip files, run on all Win platforms).
2. The solution must be based on standard DLL (not OCX, not command-prompt EXE)
3. No extra features required (password protection, multiple volumes, SFX)

you can use Pkzip/Pkunzip ...I have use it & its works fine.I gave the sample code for this earlier.for further information plz check my threads.
dima69's Avatar
Expert
 
Join Date: Sep 2006
Location: Israel
Posts: 181
#3: Jun 18 '07

re: The best VB6 solution for ZIP / UNZIP


Quote:

Originally Posted by SanjuMtr

you can use Pkzip/Pkunzip ...I have use it & its works fine.I gave the sample code for this earlier.for further information plz check my threads.

Thanks, I've seen this thread, but I'me looking for another solution (see post #1 para. 2)
Moderator
 
Join Date: Oct 2006
Location: Australia
Posts: 7,748
#4: Jun 19 '07

re: The best VB6 solution for ZIP / UNZIP


Quote:

Originally Posted by dima69

Thanks, I've seen this thread, but I'me looking for another solution (see post #1 para. 2)

the answer might depend a bit on what you mean by "all Windows platforms". Since WinXP has built-in zip file handling (never mind how good or bad the interface), it should be possible to find a a way to tap into that. But I imagine a Windows 3.0 PC might have a problem with that.
dima69's Avatar
Expert
 
Join Date: Sep 2006
Location: Israel
Posts: 181
#5: Jun 19 '07

re: The best VB6 solution for ZIP / UNZIP


Quote:

Originally Posted by Killer42

the answer might depend a bit on what you mean by "all Windows platforms". Since WinXP has built-in zip file handling (never mind how good or bad the interface), it should be possible to find a a way to tap into that. But I imagine a Windows 3.0 PC might have a problem with that.

Well, I think that the reasonable assumption would be to require Windows 98 and above.
Moderator
 
Join Date: Oct 2006
Location: Australia
Posts: 7,748
#6: Jun 19 '07

re: The best VB6 solution for ZIP / UNZIP


Quote:

Originally Posted by dima69

Well, I think that the reasonable assumption would be to require Windows 98 and above.

Fair enough. I can't remember - does Win98 handle zip files ("compressed folders") itself? Or was that introduced later? If later, then that's obviously not an option.
Moderator
 
Join Date: Oct 2006
Location: Australia
Posts: 7,748
#7: Jun 19 '07

re: The best VB6 solution for ZIP / UNZIP


By the way, I did a little hunting on the web. Here are some links that may be of interest, with the original descriptions (I didn't write them)...
  • Info-ZIP's ZIP libraries
    Info-ZIP's purpose is to "provide free, portable, high-quality versions of the Zip and UnZip compressor-archiver utilities that are compatible with the DOS-based PKZIP by PKWARE, Inc." - and they do an excellent job at it. Download their free Zip and Unzip DLLs here.
  • Zlib
    zLib is a "A Massively Spiffy Yet Delicately Unobtrusive Compression Library (Also Free, Not to Mention Unencumbered by Patents)" [ahem - that really is how the authors introduce it!] The compression algorithm used is essentially the same as used in PKZip and gzip. This is the home page for the algorithm with C code and specifications; however if you want to use it in VB, then go to:
  • Mark Nelson's OCX for ZLib
    A nice, free, fully working OCX providing access to Zlib compression and decompression. MFC source code is included. Recommended!
  • www.info-zip.org
    This last one definitely seems worth a look (Killer42)
dima69's Avatar
Expert
 
Join Date: Sep 2006
Location: Israel
Posts: 181
#8: Jun 19 '07

re: The best VB6 solution for ZIP / UNZIP


Thanks a lot to Killer for the detailed reply.
For now, I am implementing the ZLib.dll, based on the example given on Paradoxes.info
From my point of view, the advantages of zlib are:
1. Single and relatively small dll, for both compression and extraction.
2. Very liberal license, sutable for commercial use.
The disadvantages: VB implementation is not straight-forward, file handling is not included in dll, only the base data compression and decompression.

I'd be glad to see any additional comments on this.
Reply


Similar Visual Basic 4 / 5 / 6 bytes