CefSharp ChromiumWebBrowser将所有依赖项放在不同的文件夹中

问题描述 投票:0回答:1

我在winform Dotnet Framework 4.0中使用CefSharp.ChromiumWebBrowser 49.0.0

以下可执行文件/应用程序文件夹中的文

cef.pak
CefSharp.BrowserSubprocess.Core.dll
CefSharp.BrowserSubprocess.exe
CefSharp.Core.dll
CefSharp.dll
CefSharp.WinForms.dll
cef_100_percent.pak
cef_200_percent.pak
cef_extensions.pak
d3dcompiler_43.dll
d3dcompiler_47.dll
devtools_resources.pak
HAP.dll
icudtl.dat
libcef.dll
libEGL.dll
libGLESv2.dll
loc.txt
natives_blob.bin
snapshot_blob.bin
widevinecdmadapter.dll

我想将所有这些文件放在单独的文件夹中不在我的应用程序文件夹中。

我经历过像How to reference C# dll located in different folder to a C# winforms exe in different folder这样的SO帖子

但我希望CefSharp的所有相关文件在不同的文件夹或目录中。

怎么做 ?

c# .net winforms chromium cefsharp
1个回答
0
投票

尝试在引用中使用Copy Local作为FalseReferences of Project

在App.config中使用assemblyBinding:

<configuration>  
   <runtime>  
      <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">  
         <probing privatePath="bin;bin2\subbin;bin3"/>  
      </assemblyBinding>  
   </runtime>  
</configuration>  
© www.soinside.com 2019 - 2024. All rights reserved.