This project is read-only.

FolderCompress-Pass locked Files ?

Jul 27, 2009 at 1:59 PM


i want to use SevenZipSharp to Backup a big Folder. But some Files are locked or i have no access.

If a file like this in the Folder the resulting ZIP File is corrupt.

With tmp.ScanOnlyWritable = true there is no different.


My Code:


public cZip(string sxFolder, string sxZipName)

  tmp.ArchiveFormat = OutArchiveFormat.SevenZip;
  tmp.CompressionLevel = CompressionLevel.None;
  tmp.CompressionMethod = CompressionMethod.Copy;
  tmp.IncludeEmptyDirectories = true;
  tmp.DirectoryStructure = true;
  tmp.ScanOnlyWritable = true;
  sFolder = sxFolder;
  sZipName = sxZipName;
  bFolder = true; 


public void StartZip()
  if (bFolder)
  tmp.CompressDirectory(@sFolder, sZipName,true);
  catch (Exception e)
  log1.toLog("CompressDirectory", e.Message.ToString());


Pleas Help

Helge Schmitz


Jul 27, 2009 at 4:06 PM

Thanks for your request, I will see about it.