How to load assemblies outside the appbase(more information)

后端 未结 4 1725
悲&欢浪女
悲&欢浪女 2021-01-19 06:13

I want to know how to load assemblies which are outside the Appbase and Appdomain.

My problem is that I have a list of assemblies that are on a shared directory. My

4条回答
  •  Happy的楠姐
    2021-01-19 06:34

    What About MSDN - Assembly Load File

    string filePath = "C:\asmPath";
    Assembly myAssembly = Assembly.LoadFile(filePath);
    

    You can also define a probe path in your app.config (which I consider a better solution) and having the CLR loading the assemblies on demand. MSDN Probing Path

    
       
          
             
          
       
    
    

提交回复
热议问题