Oct 14, 2011 at 7:13 PM
Edited Oct 15, 2011 at 1:01 AM
I recently downloaded this library and in the process of evaluating for my project.
I have trying to unzip a zip file using the following code
// Remove the directory part of the filename just prior to unzipping
// extracting only .xyz files
zip.ToList().Where(s => !s.IsDirectory && Path.GetExtension(s.FileName) == ".xyz").ToList().
entry.FileName = Path.GetFileName(entry.FileName);
entry.CreationTime = dtUploadTime;
entry.Comment = sUser;
When the zip file is created via 7-zip the aforementioned code works fine and the unzip is successful.
However when the file is created via Winzip I get the following error "Not a valid Win32 FileTime. " Please advise.
Stacktrace results are shown below
at System.DateTime.ToFileTimeUtc() at System.IO.File.SetLastAccessTimeUtc(String path, DateTime lastAccessTimeUtc) at Ionic.Zip.ZipEntry._SetTimes(String fileOrDirectory, Boolean isFile)
at Ionic.Zip.ZipEntry.InternalExtract(String baseDir, Stream outstream, String password) at Ionic.Zip.ZipEntry.Extract(String baseDirectory, ExtractExistingFileAction extractExistingFile)
Your timely help is appreciated.