在C#中使用特定版本的dll [英] Use a specific version of a dll in C#

查看:1319
本文介绍了在C#中使用特定版本的dll的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个项目,我想使用一些特定版本的dll。

I have a project where I would want to use some specific version of a dll.

GAC包含几个版本的dll(新旧) ,我想在运行程序时使用旧的。

The GAC contains couple of versions of that dll (new & old), I would want to use the old when running the programm.

问题是,最新的dll总是从GAC中提取。

Issue is that the newest dll is always picked-up from the GAC.

你知道有没有办法:


  • 强制使用dll运行文件夹(我在解决方案中引用的文件夹,在调试中正常工作)。

  • 强制从GAC使用旧版本的dll。

谢谢!

推荐答案

在您的app.config中重定向程序集版本? http://msdn.microsoft.com/en- us / library / 7wd6ex19(v = vs.110).aspx

Have you try to "Redirecting Assembly Versions" in your app.config? http://msdn.microsoft.com/en-us/library/7wd6ex19(v=vs.110).aspx

这篇关于在C#中使用特定版本的dll的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆