Using System.IO.Packaging to ZIP your files

added by galratner
1/24/2011 9:41:15 AM

357 Views

System.IO.Packaging provides storage support for multiple data objects in a single container. System.IO.Packaging uses the ZIP file format as its primary physical format for a Package. Other Package implementations might use an XML document, a database, or Web service. The following contains a utility class I wrote to help zip a file or a folder into a ZIP archive. This is an asynchronous as is suitable for invoking from a WPF or a Silverlight Application when we need to display a progress bar. Here is the code:


0 comments