如何修复引用旧(测试版).NET 版本的程序集?
我正在尝试在 Visual Studio 2010 中编译一个项目。它在 Visual Studio 2008 中工作正常,但 2010 给出以下错误:
无法解析主要引用“TiS.Core.eFlowAPI”,因为它间接依赖于 .NET Framework 程序集“mscorlib,Version=2.0.3600.0,Culture=neutral,PublicKeyToken=b77a5c561934e089”,该程序集具有更高的版本“2.0.3600.0”比当前目标框架中的版本“2.0.0.0”。
我已经找到了 MDbgCore.dll 的罪魁祸首。该程序集包含在(在依赖链中)并且它正在寻找 mscorlib 2.0.3600.0。
经过一些研究后,它看起来像是 .NET 2.0 的 Beta 版本。
我该如何解决这个问题?我无权访问此第三方 DLL(即 TiS.Core.eFlowAPI)的代码。
I'm trying to compile a project in Visual Studio 2010. It worked fine in Visual Studio 2008 but 2010 is giving the following error:
The primary reference "TiS.Core.eFlowAPI" could not be resolved because it has an indirect dependency on the .NET Framework assembly "mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "2.0.3600.0" than the version "2.0.0.0" in the current target framework.
I've tracked down the culprit to MDbgCore.dll. This assembly is included (in a dependency chain) and it is looking for mscorlib 2.0.3600.0.
After doing some research it looks like that is a beta version of .NET 2.0.
How do I solve this problem? I don't have access to the code of this third party DLL (ie. TiS.Core.eFlowAPI).
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
我已经解决了。也许是错误的方式,但我使用 Reflexil 修改有问题的 DLL,使其指向正确的 .NET 版本。
I've solved it. Perhaps the wrong way but I used Reflexil to modify the offending DLL so it pointed to the correct version of .NET.
尝试创建一个新项目并引用正确的程序集。然后将代码复制并粘贴到您的项目中
Try creating a new project and referencing the correct assembly. then copy and paste the code into your project
您可以尝试程序集重定向。我不确定这是否适合您,但我相信可以检查一下:
You can try assembly redirection. I'm unsure about if this is the solution for you, but I believe that can be something to check:
我也有同样的问题。我可以通过重命名/删除目标目录中的
MdbgCore.dll
来解决它。I had the same problem. I was able to resolve it by renaming / deleting the
MdbgCore.dll
in the target directory.