Unzip Requires Password..

Apr 5, 2012 at 5:38 AM

Hello All:

I'm Zipping a single file into an archive (foo.txt) and adding the extension of '.zip' to it.  Everything works just fine.  I'm able to double click on the file under Windows XP and view the contents just fine.

The problem arises when I try to extract the file by right clicking on the .Zip file and selecting Extract All.  It asks for a password.  My code is as follows:

        Dim lZip As Ionic.Zip.ZipFile = Nothing

        Dim rstrFile as string = "C:\Junk\Foo.TXT"

       'Zip a single file and add a '.zip' extension
        lZip = New Ionic.Zip.ZipFile(rstrFile & ".zip")
        lZip.CompressionLevel = Ionic.Zlib.CompressionLevel.BestCompression
        lZip.FlattenFoldersOnExtract = True


Oh, and the code is in VB.NET 2005.

Mike B.
Riverview, FL

Apr 9, 2012 at 8:16 PM

Ok.  I've been able to diagnose this a bit further.  I can decompress the file on a Windows7 (32 bit) machine just fine.  It seems to be a comparability problem with Windows XP.

Any help would be greatly appreciated.

Mike B.

Apr 9, 2012 at 8:21 PM

Oh.  One last item:

In my sample code, the line:


should actually read: