1. Get DLL for
http://dotnetzip.codeplex.com/[
^]
2. Add a reference to the DLL.
3. Import the namespace by adding: using Ionic.Zip;
and use the following code
using (ZipFile zip = new ZipFile())
{
zip.AddFile("C:\test\test.txt");
zip.AddFile("C:\test\test2.txt");
zip.Save("C:\output.zip");
}
Hope this helps