C# 将.dll添加到VS 2012安装项目

C# 将.dll添加到VS 2012安装项目,c#,C#,我的项目有一个.dll作为引用,它是(HtmlAgilityPack),当我执行安装项目时,它返回一个错误 See the end of this message for details on invoking just-in-time (JIT) debugging instead of this dialog box. ************** Exception Text ************** System.IO.FileNotFoundException: Could n

我的项目有一个.dll作为引用,它是(HtmlAgilityPack),当我执行安装项目时,它返回一个错误

See the end of this message for details on invoking 
just-in-time (JIT) debugging instead of this dialog box.

************** Exception Text **************
System.IO.FileNotFoundException: Could not load file or assembly 'HtmlAgilityPack,
Version=1.4.6.0, Culture=neutral, PublicKeyToken=bd319b19eaf3b43a' or one of its   
dependencies. The system cannot find the file specified.

如何解决此问题?

您需要确保所需的DLL已存在于目标系统中,或者与应用程序一起安装。此错误消息表示未找到所需的DLL,因此无法加载


如果使用Visual Studio安装项目安装应用程序,请在“依赖项”下查看所需的dll是否存在,以及是否也包含在安装程序中。

如果它只是一个参考dll,并且不打算安装,则可以将其添加到执行文件的根目录中,其中有yourapplication.exe

要使其成为单个安装文件,可以使用Visual Studio的setup maker或其他可用软件


希望有帮助

是的,我知道,2008年自动添加了.dll,但在2012年,我不知道如何添加它。我的问题是如何添加.dll。2012年不再有安装项目。仅限WiX和InstallShield LE。哪一个?很高兴我能帮上忙。:)