且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何在asp.net应用程序中拥有多个bin文件夹?

更新时间:2022-11-06 19:17:19

您可以在web.config中添加一个assemblyBinding元素来设置多个bin路径:

You can add an assemblyBinding element to your web.config to set multiple 'bin' paths:

<configuration>
   <runtime>   
      <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
         <probing privatePath="bin;SubApp1\bin;SubApp2\bin"/>
      </assemblyBinding>
   </runtime>   
</configuration>

这将导致您的主Web应用程序使用探测元素。

This will cause your main web application to use DLLs from all of the bin paths in the probing element.