简体   繁体   English

防止从GAC加载dll

[英]Prevent loading a dll from GAC

I have an Aspx page with no .cs file. 我有一个没有.cs文件的Aspx页面。 This page is using a dll file which is already in the GAC of my machine. 该页面使用的是我计算机GAC中已经存在的dll文件。 I have a new version of this dll, but I don't want to change anything in the GAC. 我有此dll的新版本,但我不想更改GAC中的任何内容。 Can I make this aspx page load the dll from my bin directory and override the GAC? 我可以使此aspx页从bin目录中加载dll并覆盖GAC吗?

Thanks! 谢谢!

Yes. 是。 Just put new assembly to folder where your application binaries are and use assembly redirection Assembly Redirection 只需将新程序集放在应用程序二进制文件所在的文件夹中,然后使用程序集重定向即可。

And make sure your assembly version has changed. 并确保您的程序集版本已更改。

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

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