Alex Rivera | Logout

Compressing / Decompressing Folders & Files

Asked 2008-08-01T17:13:08.933
60

Does anyone know of a good way to compress or decompress files and folders in C# quickly? Handling large files might be necessary.

Edit
Report

2 Answers

10

You can use a 3rd-party library such as SharpZip as Tom pointed out.

Another way (without going 3rd-party) is to use the Windows Shell API. You'll need to set a reference to the Microsoft Shell Controls and Automation COM library in your C# project. Gerald Gibson has an example at:

Internet Archive's copy of the dead page

answered 2008-08-01T18:04:25.023
6

GZipStream is a really good utility to use.

answered 2012-05-13T02:01:39.030

Your Answer