I’m using the ZipPackage-class in .NET to read and write zip-files. But how do I get basic file properties from files within a zip-package? I’m specifically looking for the date-times Created and Modified. I would prefer to not depend on a external lib of course, but it may be unavoidable…
Share
I have never used the ZipPackage class, so I can’t comment on that. But using other libraries, this should be easily possible. E.g. using DotNetZip, the following snippet extracts information about all entries (files) of a zip archive:
List entries in a zip. List all the entries in a zip file:
(Class
ZipEntryhas other properties such as CreationTime, AccessdTime, etc.).