c# - My project references another project which references a 3rd party assembly. How do I set the assembly path for this 3rd party assembly? -
my project references project b. project b holds reference 3rd party assembly. project located in folder project b , 3rd party assembly (due integration software). know have assemblies in integration folder, have them in own folder have other assemblies executable used diagnose , setup module.
i have subscribed myresolveeventhandler
in project in appdomain.currentdomain
, , can set correct assembly path of project b. problem occurs when project calls method in project b 3rd party assembly used. throws filenotfoundexception
assembly, , display path of integration folder rather folder set project b in myresolveeventhandler
.
i've tried appdomain.currentdomain.load(assemblyname.getassemblyname(@"pathof3rdpartyassembly"))
, tell me loaded assembly in appdomain
, still throw same filenotfoundexception
mentioned above.
how can set assembly path of 3rd party assembly used within project b project a?
edit: sorry, problem caused hidden bug myself. implemented dll hijacking countermeasures throwing filenotfoundexception. when correct assembly path project b set, valid 3rd party application referenced in project b. sorry wasting time... can assure wasted lot of time before asking question, when asking question, , after asking question. gotta move on... :) suggestions! upvote both of you...
you can setup custom probing path 3rd party assembly. please note approach won't work asp.net applications (they don't support custom probing paths).
Comments
Post a Comment