Could not extract files! Message: The extraction has failed for an unknown reason with code -2146232798.

Apr 19, 2009 at 9:18 AM
Edited Apr 19, 2009 at 9:18 AM
hi, exception throws when extracting files one by one like this:

            using (SevenZipExtractor e = new SevenZipExtractor(@"c:\temp\a.7z"))
            {
                for (int i = 0; i < e.ArchiveFileData.Count; i++)
                {
                    e.ExtractFile(e.ArchiveFileData[i].Index, @"C:\temp\aa\");
                }
            }

but it will work like this:

            using (SevenZipExtractor e = new SevenZipExtractor(@"c:\temp\a.7z"))
            {
                e.ExtractArchive(@"C:\temp\aa\");
            }

I am using latest 7z.dll 9.0 beta.

here is my sample 7z file: http://files.cnblogs.com/unruledboy/a.7z




Coordinator
Apr 19, 2009 at 10:24 PM
I am trying to do hardcore optimizations now, so use the initial 0.42 release.