简体   繁体   English

DLL文件解压缩vb.net和vs2012中的RAR存档

[英]DLL file to unrar a RAR archive in vb.net and vs2012

I need a little help with my vb.net programming as I am trying to unrar a RAR archive. 我需要一些关于我的vb.net编程的帮助,因为我正在尝试解开RAR存档。 I have the latest version from Chilkat for VS2012 in VB.NET, but it does not include a Chilkat.RAR method. 我在VB.NET中使用Chilkat for VS2012的最新版本,但它不包含Chilkat.RAR方法。 I have tried using unrar.dll v3.9.3, but I cannot add the reference to my project because it is not compatible with VS2012. 我曾尝试使用unrar.dll v3.9.3,但我无法添加对我的项目的引用,因为它与VS2012不兼容。 It says that the DLL is not a valid assembly and to check and make sure it is a valid assembly. 它说DLL不是一个有效的程序集,并检查并确保它是一个有效的程序集。 I just need something that can unrar a RAR archive (no password method needed, and preferably only 1 file, not all files in a directory). 我只需要能够解开RAR存档的东西(不需要密码方法,最好只有1个文件,而不是目录中的所有文件)。 This has to be compatible with the .net framework 4.0 AND/OR 4.5 AND MUST be able to be referenced in Microsoft Visual Studio 2012 Pro(VB.NET Environment). 这必须与.net框架4.0和/或4.5兼容,并且必须能够在Microsoft Visual Studio 2012 Pro(VB.NET环境)中引用。

Unrar.dll from RARLAB (http://www.rarlab.com/rar_add.htm) is a native library, so you cannot add it as a reference in a VB.NET project. 来自RARLAB的Unrar.dll(http://www.rarlab.com/rar_add.htm)是一个本机库,因此您无法将其作为VB.NET项目中的引用添加。 You have to use Platform Invoke to consume its API, and that's what Chilkat's RAR library is based on. 您必须使用Platform Invoke来使用它的API,这就是Chilkat的RAR库所基于的。

If you want a managed library, you can check out http://sharpcompress.codeplex.com . 如果您需要托管库,可以查看http://sharpcompress.codeplex.com

Sevenzipsharp.codeplex.com is based on 7-zip's native library, so it claims to support RAR format. Sevenzipsharp.codeplex.com基于7-zip的本机库,因此声称支持RAR格式。

dotnetzip.codeplex.com is a managed ZIP library, which does not support RAR, and @Steve should not state it in the comment. dotnetzip.codeplex.com是一个托管ZIP库,它不支持RAR,而@Steve不应在评论中说明它。

SharpCompress is a compression library for .NET/Mono/Silverlight/WP7 that can unrar, un7zip, unzip, untar unbzip2 and ungzip with forward-only reading and file random access APIs. SharpCompress是.NET / Mono / Silverlight / WP7的压缩库,可以通过只读和文件随机访问API解压缩un7zip,解压缩,解压缩unbzip2和ungzip。 Write support for zip/tar/bzip2/gzip is implemented. 写入对zip / tar / bzip2 / gzip的支持已实现。

The major feature is support for non-seekable streams so large files can be processed on the fly (ie download stream). 主要功能是支持不可搜索的流,因此可以即时处理大型文件(即下载流)。

Now on GitHub: https://github.com/adamhathcock/sharpcompress 现在在GitHub上: https//github.com/adamhathcock/sharpcompress

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM