This topic demonstrates how to list the contents of a zip file using the static GetZipContents method of the QuickZip class.
To list the contents of a zip file, the following steps must be performed:
Declare an array of QuickZipItem objects that will contain the result of the call to the GetZipContents method.
Iterate through the array of QuickZipItem objects to retrieve information on each QuickZipItem object it contains.
This example demonstrates how to list the contents of a zip file.
VB.NET | Copy Code |
---|---|
|
C# | Copy Code |
---|---|
|
Zip files are case sensitive therefore the string passed in the fileMasks parameter, will be used "as-is". For example, if a zip file contains a file named "FILE.TXT" and "file.txt" is passed to the fileMasks parameter, "FILE.TXT" will not be retrieved.
The main questions you should ask yourself when listing the contents of a zip file are: