【发布时间】:2015-10-27 08:37:39
【问题描述】:
在我的应用程序中,我想将 DLL 文件放在一个子目录中。我在 app.config 中使用 probing 元素,它工作得很好,但我遇到了本地化程序集的问题。
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<probing privatePath="libs"/>
</assemblyBinding>
如果我有两个 DLL:
libs/de/myAssembly.dll
和
libs/myAssembly.dll
第一个已加载,而我希望根文件夹中的文件是首选。我怎样才能做到这一点?
【问题讨论】:
-
我发现问题仅与资源的 dll 以及我实现 AssemblyResolve 事件处理程序的方式有关。现在我在加载程序集之前测试cultureInfo。