在启动文件中,我已经添加了以下内容:
var context = new CustomAssemblyLoadContext();
context.LoadUnmanagedLibrary(Path.Combine(Directory.GetCurrentDirectory(), "libwkhtmltox.dll"));
在启动Web应用程序时,这行代码会出现以下错误:
DllNotFoundException:无法加载DLL'C:\Program Files\IIS Express\libwkhtmltox.dll'或其依赖项之一:指定的模块无法找到。(HRESULT异常:0x8007007E)
System.Runtime.Loader.AssemblyLoadContext.InternalLoadUnmanagedDllFromPath(string unmanagedDllPath)
DllNotFoundException:无法加载DLL'C:\Program Files\IIS Express\libwkhtmltox.dll'或其依赖项之一:指定的模块无法找到。(HRESULT异常:0x8007007E)