Quantcast
Channel: DotNetZip Library
Viewing all 664 articles
Browse latest View live

Created Issue: Allow install on Windows XP [16097]

$
0
0
The msi installer currently stops saying it can not be installed on Windows XP.

The install should be allowed as long as a suitable version of .Net has been installed.

New Post: Extracting content to string via COM

$
0
0
I have a VBA/VB6 application that is using AddEntry and UpdateEntry in a zip file where the content is provided by a string. This all seems to work well.

However, I don't seem to be able to find a way to read an entry into a string. I am trying to avoid extracting the file to the file system. It also does not seem possible to make use of the streams with COM.

Any suggestions or examples?

New Post: Fails to install on Windows XP

$
0
0
Seems I was able to use Orca to modify the msi file so that it allows Windows XP installs.

Commented Issue: "Path is empty" when extracting in a linux system. [15236]

$
0
0
When using the following code:
 
ZipFile zip = ZipFile.Read(ms);
zip.ExtractAll(LatestPath);
 
An "Path is empty" exception message is triggered by that DotNetZip tries to pass "" to Directory.Create() in ZipEntry.Extract, line 760.
 
The cause is that the variable targetFileName contain the path using "\" as directory separator. When run on linux the path is interpreted as a single filename making the directory path "".
 
I would guess it could be fixed in the method ValidateOutput() in the same file line 1417:
- outFileName = outFileName.Replace("/","\\");
+ outFileName = outFileName.Replace('/', Path.DirectorySeparatorChar);
 
It works but someone who knows it should have a look at it.
Comments: ** Comment from web user: edgarrc **

Thank you, I hope this fix is already merged on main stream, worked perfectly on linux-mono.

Created Issue: Name Clash of the Temp Files [16103]

$
0
0
Our applicaiton is creating hundreds of ZIP files on the fly using several worker threads to do this. Each worker thread has its own directory to work in, and each new ZIP file is created in this directory. We have used the ZIP class property TempFileFolder to have ZIP create the temp files in separate directories for each worker thread.

But what we have found is that the tmp file created by the ZIP class are still suffering name clashes. It could be that the algoritm for determining temparary file names is not discrete enough to come up with unique names in such a rapid progression as we are genrating ZIPs at a rate of 6 - 10 per second. Or if the tempary file name is based on the source file it could be that since the source files differ by only a singe character, the temparay file name's hash value is not unique?

Either way can you offer a hint or tip that might help us work around this issue?

Commented Issue: Feature Request: LZMA (7 Zip) Support [14034]

$
0
0
Greetings,
 
I would like to request support for LZMA implemented with the same design you use for your Zip implementation from a class point of view. So that someone who uses your Zip library can easy pickup and use your LZMA one. With the AES128 and AES256 encryption options.
 
There is a C# LZMA reference implementation that is Public Domain on the 7-zip.org site's SDK:
http://www.7-zip.org/sdk.html
 
Also the SevenZipSharp project here on codeplex has a managed C# implementation based on the reference one. It is not a compatible license but the owner is very reasonable and if you ask he will most likely give you permission to fork his LZMA managed implementation under Ms-PL, as he has given to me.
 
I use your library to do all the Zip and GZip needs, and I use the other for my LZMA needs but the SevenZipSharp managed implementation needs some work performance wise, and it lacks encryption. I was planning to do that if I have time, but that would still give me two libraries, so I figured I could at least ask if you could include this into your Library that would help reduce everything for me to a single library under an active and well maintained project which would be great.
 
Kind Regards...
Comments: ** Comment from web user: CreepyGnome **

bump

Any possibility of this being implemented?

Created Issue: the final hash has not been computed [16105]

$
0
0
Recently I have run into a few zip files which were created using DotNetZip which I cannot unzip with DotNetZip but I can unzip with WinZip. In each case, the unzip stops with an error that reads: "the final hash has not been computed". I have tried unzipping the same with the DotNetZip-WinFormsTool.exe that comes with the Development Kit and it too produces the same error.

The error happens consistently and at the same point each time. I looked at the particular file in the .zip that it fails on and can find nothing wrong with it (after extracting it using WinZip). Unfortuneatly, the three files that I can reproduce the problem with are each larger than 4MB so I cannot attach them to this post.

I found posts related to the same problem but no resolution. Any ideas?

New Post: Is this lib deprecated?

$
0
0
Maybe they just want people to buy their commercial offering.

New Post: AddDirectory Progress

$
0
0
Thanks for a great resource!
I've got it working fine including showing progress while the zip file saves. However there is a long pause after
zip1.AddDirectory(options.Folder)
and I would like to add a progress bar to this line. Is this possible? I've tried unsuccessfully adapting the zip1.SaveProgress.

Commented Issue: ZipSL runtime error - TypeInitializationException due to IBM437 Encoding defaults [14049]

$
0
0
Hi,
 
Awesome library! Got up and running in seconds - you've certainly led we customers into the "Pit of Success." :)
 
This may be already known, but I encountered runtime TypeInitializationException(s) when using types (such as ZipFile and ZipEntry) in ZipSL 1.9.1.8 from with a Silverlight application. After building and running from source, it was clear that the problem
was related to the static type construction at lines such as:
 
AlternateEncoding = System.Text.Encoding.GetEncoding("IBM437");
 
 
Appears this encoding is not one of the
four supported encodings in SL4. I was able to avoid the issue by altering the behavior where necessary with preprocessor directives, for example:
 

 
 
#if SILVERLIGHT
AlternateEncoding = System.Text.Encoding.GetEncoding("utf-8");
#else
AlternateEncoding = System.Text.Encoding.GetEncoding("IBM437");
#endif
 
I was able to do this to the point where my use cases were covered; would be happy to submit a patch if I had some guidance on the most appropriate strategy for dealing with this.
 
Yours,
David
Comments: ** Comment from web user: KeithW **

Just adding some support for this patch, would love to get it in the next release.

Reviewed: v1.9.1.8 DotNetZip - Latest Stable (mar 19, 2013)

$
0
0
Rated 5 Stars (out of 5) - That was too easy to compress files using this library!

New Post: Is this lib deprecated?

$
0
0
@AndyJW By commercial offering - do you mean Xceed? I'm curious about the relationship between XCeed and DotNetZip.

Reviewed: v1.9.1.8 DotNetZip - Latest Stable (Mrz 22, 2013)

$
0
0
Rated 5 Stars (out of 5) - Great. Thanks for that work and the VB.Net samples!!

New Post: Extracted file from SFX option becomes hidden by default

$
0
0
We are using SFX option to create a self-extractable compressed file. Usually one or more files which are part of the exe. We rename them in order to attach it with emails. When user saves the attachment to their local and run self-extractable exe, the file gets extracted but become hidden file. when we change folder view option to show hidden files, we could see the extracted files. But we want them to be extracted and displayed like normal files. We tried it in Win7 and 8 machines. Would appreciate any help. Thanks, arockiaraj, D.

New Post: Is this lib deprecated?

$
0
0
Yes, there seems to be some sort of link

New Post: Force a flush?

$
0
0
Calling Flush() on a GZipStream doesn't seem to do anything - is there any way I can force it to flush its buffers to disk?

New Post: .tmp file - quick question (ZIP)

$
0
0
Same problem here. March, 2013.

The only workaround right now is to recursively delete *.tmp before unzipping.
myOutputDirectory.GetFiles("*.tmp", SearchOption.AllDirectories).ToList().ForEach(file=>file.Delete());
Léon Pelletier

Created Issue: Rename entry problem [16130]

$
0
0
In the Reduced v1.9.1.8 DotNetZip release there is an issue with renaming an entry.

__To reproduce__
1. Use another archiver program to create a ZIP archive that contains an entry with a full Windows path (e.g. `C:\Users\Test\Documents\myfile.txt`).
2. Let DotNetZip open the archive, rename the file, and save the archive.
3. The archive now contains _two_ files that seem to point to the same entry. One with the old filename, one with the new filename.
4. WinRAR thinks the archive is corrupt, 7zip and Windows Explorer will extract either of the two files.

__The code (for step 2)__
```
using (ZipFile zip = ZipFile.Read("test.zip"))
{
ZipEntry entry = zip.Entries.FirstOrDefault(e => Path.GetFileName(e.FileName) == "myfile.txt");
entry.FileName = Path.Combine(Path.GetDirectoryName(entry.FileName), "newfile.txt");
zip.Save(@"test2.zip");
}
```

__The underlying cause__
When renaming an entry the entry with the old filename is removed from `_entries`. However, it uses the normalized filename as the key to remove, but `_entries` (and the entry's `Filename` property) sometimes contains the unnormalized filename (read directly from the file). So the old entry doesn't get removed. It doesn't check that exactly one key-value pair is removed.

This issue was first encountered by a user who posted a [question on Stackoverflow](http://stackoverflow.com/q/15601189/146622).

New Post: how to subscribe to an event

$
0
0
I've searched the documentation and examples for how to let the system know I want to see events such as the progress of a save, but I didn't find anything that looked familiar to me.

Can someone please enlighten me as to how to subscribe to one of DotNetZip's events?

Thanks, Chuck

Created Issue: DotNetZip created zip does not open on double click[opens using 7 zip extract] [16141]

$
0
0
DotNetZip created zip does not open on double click[opens using 7 zip extract].

After downloading the zip, if we double click on zip, error pops up,

Windows cannot open the folder
The compressed(zipped) folder is [folder name] invalid.

But if we extract downloaded zip using 7 Zip it displays proper files.

The code used is,

string archiveName = String.Format("archive-{0}.zip", DateTime.Now.ToString("yyyy-MMM-dd-HHmmss"));
Response.ContentType = "application/zip";
Response.AddHeader("content-disposition", "filename=" + archiveName);
using (ZipFile z = new ZipFile())
{
z.AddEntry("test1.csv",csvData);
z.Save(Response.OutputStream);
}
Response.Flush();
Response.Clear();

Please let me know if anyone has any idea about this.
Thanks
Viewing all 664 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>