How can Extract a ZipFile in C#? (ZipFile is include file and Directory)
+8
A:
Use a tool for that. Something like SharpZip. As far as I know - .NET does not support ZIP files out of the box.
From here =>
There are 2 problems with this class.
- It does not handle ZIP files.
- It is dysfunctional, can actually inflate data in "compression".
There's something wrong with the logic. It's a known problem but as yet unfixed.
So - if you need to work with ZIP files, gzipstream won't help. Otherwise - it should work fine.
Arnis L.
2010-02-23 09:38:57
+1 I tend to see SharpZip used a lot
MPritch
2010-02-23 09:47:29
+1 the right answer, first time
Asad Butt
2010-02-23 10:22:57
Does any library support RAR files?
Tuoski
2010-02-23 12:54:35
@Tuoski http://stackoverflow.com/questions/11737/net-library-to-unzip-zip-and-rar-files
Arnis L.
2010-02-23 13:48:04