我将使用sevenzipsharp 从iso 文件中提取文件到usb。为此,我从 vs nuget 包管理器下载了sevenzipsharp,并编写了代码(实际上我不能:))这段代码。我没有任何错误,但它不起作用。我在哪里犯错?请写详细信息。
if (IntPtr.Size == 8) //x64
{
SevenZip.SevenZipExtractor.SetLibraryPath(@"C:\Program Files\7-Zip\7z.dll");
}
else //x86
{
SevenZip.SevenZipCompressor.SetLibraryPath(@"C:\Program Files (x86)\7-Zip\7z.dll");
}
using (var file = new SevenZipExtractor(sourcePath))
{
file.ExtractArchive(outputPath);
}
先感谢您