gpt4 book ai didi

c++ - REGSVR32: 模块 "xxxxx.dll"加载失败...找不到相关程序集

转载 作者:可可西里 更新时间:2023-11-01 12:44:48 25 4
gpt4 key购买 nike

我在 Windows 7 x64 下注册 *.dll 时遇到问题。

我尝试将 *.dll 放在 C:/Windows/System32 和 C:/Windows/SysWOW64 中,并尝试在提升的命令提示符下注册“regsvr32 xxxxx.dll”。我还尝试从一个单独的目录注册它。它响应以下错误:

The module "xxxxx.dll" failed to load.
Make sure the binary is stored at the specified path or debug it to check for problems with the binary or dependent .DLL files.
The application has failed to start because its side-by-side configuration is incorrect. Please see the application event log or use the command-line sxstrace.exe tool for more detail.

事件日志注释:

Activation context generation failed for "C:\(path-to-dll)
Dependent Assembly
Microsoft.VC90.ATL,processorArchitecture="x86",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8" could not be found.
Please use sxstrace.exe for detailed diagnosis

注意我已经安装了 x86 和 x64 Microsoft Visual C++ 2010 Redistributables。

有趣的是,我试图在我的工作 x64 Windows 7 笔记本电脑上注册相同的 *.dll,并且它按预期注册了。我猜这倾向于这样一个事实,即缺少某种 C++ 依赖项/与 ATL 相关?

如果有人能帮助我指出正确的方向或对此事有任何额外的了解;我将不胜感激。

问候。

最佳答案

这几乎可以肯定是由于缺少依赖项。使用类似 Dependency Walker 的工具找到所需的 DLL 依赖项。或者,如果 DLL 由第三方提供,请阅读他们的文档,其中应指定所需的依赖项。

请注意,Microsoft.VC90.ATL 表示 MSVC 的版本 9,即 VS2008。因此,您需要安装 MSVC 2008 运行时以满足该依赖性。您似乎错误地安装了 MSVC 2010 运行时。

最后,请不要将文件放到系统目录下。它属于系统,不应由您修改。

关于c++ - REGSVR32: 模块 "xxxxx.dll"加载失败...找不到相关程序集,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27290154/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com