Click here to Skip to main content
15,890,609 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
See more:
Hello,

Assembly probing - how to instruct runtime to look under bin folder instead of GAC?

According to this article[^], runtime default behavior is to check GAC BEFORE other location.

So the fact that I added probing hint didn't change this (i.e. runtime is still binding to dll in GAC):
<br /><assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"><br /> <probing privatePath="bin;bin\Debug;bin\Release;"/><br /> </assemblyBinding><br />
But this is NOT what I need, I actually need it to go bin folder for it?

This may be relevant.[^]

Also how can I check which version is being binded to? I launched "fuslogvw" but it is just sitting there. Nothing shows for some reason... it's giving me headache because (a) dll in GAC no debug information (even under DEBUG build)
(b) nHibernate mapping files loading - my mapping files are in bin folder, not in GAC

Thanks

Posted

1 solution

AppDomain.CurrentDomain.AssemblyLoad

and

AppDomain.CurrentDomain.AssemblyResolve

You may be able to write some code with those events to accomplish your goals.

 
Share this answer
 


CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900