你这样加载dll 还要写两遍,一遍是在CS文件里,另一边还要在代码里加载,太费事了。 
我是这样加载的 
foreach (string FilePath in Directory.EnumerateFiles(Path.Combine(ModuleDirectory, "../../../Binaries/ThirdParty/XXXX/Win64/"), "*", SearchOption.AllDirectories)) 
            { 
                RuntimeDependencies.Add(new RuntimeDependency(FilePath)); 
            } 
        } 
 
直接把dll 加载了,跟静态一样的。 之后代码里加上头文件直接引用就可以了 |