To create a zip file in Unicode in DotNetZip:
using (var zip = new ZipFile())
{
zip.UseUnicodeAsNecessary= true;
zip.AddFile(filename, "directory\\in\\archive");
zip.Save("archive.zip");
}
If you need a specific specific code page, you should use something else:
using (var zip = new ZipFile())
{
zip.ProvisionalAlternateEncoding = System.Text.Encoding.GetEncoding(866);
zip.AddFile(filename, "directory\\in\\archive");
zip.Save("archive.zip");
}
Check the documentation for these properties before using them!
source
share