Jun 13, 2013 at 9:35 PM
Edited Jun 14, 2013 at 9:46 PM
I'm trying to use DotNetZip to zip directories for back-up. I'm using the following script, based heavily on one I found in the PowerShell examples.
[System.Reflection.Assembly]::LoadFrom('c:\Users\Walter\Documents\WindowsPowerShell\Modules\WalterMetcalf\DotNetZip\Ionic.Zip.dll');` The script give a "Access denied" exception error on a file called TV_Music.ini, supposedly in a sub-directory which doesn't contain it--UNTiL you turn on "Display Hidden Files" in Windows Explorer! During my
testing I have had the exception occur on other files, which apparently don't exist.
$directoryToZip = 'c:\Users\Walter\Documents\';
$zipfile = new-object Ionic.Zip.ZipFile;
$e= $zipfile.AddEntry("Readme.txt", "This is a zipfile created from within powershell.");
$e= $zipfile.AddDirectory($directoryToZip, "home");
I'm guessing these files are re-parse items, but turning off (=FALSE) the "WillTraverseReparsePoints" property only make the problem worse.
Any ideas, suggestions?
P.S. I'm using update 188.8.131.52 of the library; PS 3.0 on Windows 7 SP1
PPS. I have since (13 June) verified that the files causing the problem are, in fact, RecursePoints.