andrew Sullivan
andrew Sullivan

Reputation: 4084

Content inside zip file

how to use zippackage class to know about the content in .zip file? for ex to know the type of file inside this zip file.

Upvotes: 2

Views: 504

Answers (2)

shelleybutterfly
shelleybutterfly

Reputation: 3247

http://sharpdevelop.net/OpenSource/SharpZipLib/ is a good zip library for CSharp.

Although, you might just want to use something like the DeflateStream class (http://msdn.microsoft.com/en-us/library/system.io.compression.deflatestream.aspx) which provides a compressed stream and doesn't require dealing with the complexities of an archive that handles multiple files.

Upvotes: 0

Oded
Oded

Reputation: 499072

Once you open the .zip file, you can use the GetParts method to get a collection of all the files inside the .zip. See the PackagePart class.

Upvotes: 4

Related Questions