Forcing the ASP.NET Application to load the assembly from bin not from GAC

后端 未结 8 1447
死守一世寂寞
死守一世寂寞 2020-12-15 21:18

Is there any way to force my asp.net application to load the assembly from local bin directory since there is another older version of the assembly with the same name in the

8条回答
  •  误落风尘
    2020-12-15 21:55

    Based on the excerpted notes on assembly loading order in this answer: How to prevent a .NET application from loading/referencing an assembly from the GAC?

    I am guessing that calling LoadLibrary on the local DLL file before asking the library to load as an assembly, might move it up in the search order for you.

    Sadly, I am not sure how to get your LoadLibrary call to run before the framework starts loading referenced assemblies.

    So this is just an idea, not a full answer.

提交回复
热议问题