I have a zip archive with subfolders. For example, in TotalCommander there is:
DIAG_CONTAINER.zip\template\xyz\src\params\MyParam.xml
I want to extract the whole DIAG_CONTAINER.zip into a new folder DIAG_CONTAINER and preserve the hierarchy of the files and folders. I use this code:
zipFile.Open(sourceFile);
zipFile.Entries.ExtractFolder(destFolder);
But the last call throws an UnauthorizedAccessException saying that the directory "DIAG_CONTAINER\template" cannot be accessed. I checked via TotalCommander that the created directory is set to ReadOnly and it seems that no files can be copied into it. When the method "ExtractFolder" is called, does it create the new folders as ReadOnly?