Encodingencoding=Encoding.GetEncoding(866);using(Metadatametadata=newMetadata(Constants.InputZip)){varroot=metadata.GetRootPackage<ZipRootPackage>();Console.WriteLine(root.ZipPackage.Comment);Console.WriteLine(root.ZipPackage.TotalEntries);foreach(varfileinroot.ZipPackage.Files){Console.WriteLine(file.Name);Console.WriteLine(file.CompressedSize);Console.WriteLine(file.CompressionMethod);Console.WriteLine(file.Flags);Console.WriteLine(file.ModificationDateTime);Console.WriteLine(file.UncompressedSize);// Use a specific encoding for the file namesConsole.WriteLine(encoding.GetString(file.RawName));}}
Updating the user comment
GroupDocs.Metadata for .NET allows you to update the user comment in a ZIP archive. The following steps are needed to be followed:
GroupDocs.Metadata for .NET allows you to remove the user comment associated with a ZIP archive. The following code snippet demonstrates the usage of this feature.
Along with full featured .NET library we provide simple, but powerful free Apps.
You are welcome to view and edit metadata of PDF, DOC, DOCX, PPT, PPTX, XLS, XLSX, emails, images and more with our free online Free Online Document Metadata Viewing and Editing App.
Was this page helpful?
Any additional feedback you'd like to share with us?
Please tell us how we can improve this page.
Thank you for your feedback!
We value your opinion. Your feedback will help us improve our documentation.