c++ - COM msado15.dll 程序已停止运行

标签 c++ windows-8 windows-7 com ado

我们一直在我们的程序中使用旧的 msado15.dll。我们曾经导入它 #import "msado15.dll"。现在就在几天前,我们升级到 Windows 8。唉,我们的软件在没有安装 Service pack 1 的 Windows 7 上停止工作。 早些时候,当我们使用 Windows 7 时,我们已经升级到 Service pack 1 并且发生了同样的问题,因此我们从所有机器上卸载了适用于 Windows 7 的 Service Pack 1,并且一切正常。

但对于 Windows 8,我想他们已经更改了 msado15.dll。 我在网上做了一些研究,他们说我们应该用 msado60.tlb 替换导入,但这也对我们的编译中断不起作用。

这就是我们过去在 C++ 环境中引用的方式

import "c:\program Files\Common Files\system\ado\msado15.dll" rename_namespace("ADOCG") rename("EOF","EndofFile") 

我改成了

import "c:\program Files\Common Files\system\ado\msado28.tlb" rename_namespace("ADOCG") rename("EOF","EndofFile")

也尝试过

import "c:\program Files\Common Files\system\ado\msado60.tlb" rename_namespace("ADOCG") rename("EOF","EndofFile")

根据微软的建议Link .但它仍然无法在未安装 Service pack 1 的 XP 机器和 Windows 7 机器上运行。

任何人都可以建议我们可以遵循的正确步骤,以便让我们的程序在没有 Service Pack 1 的 Windows 7 和 Windows 8 上运行。

这几天一直被这个问题困扰。帮助将不胜感激。

此致, 紫罗兰

最佳答案

这是根据 Saurabh 的评论解决的:

What we did was similar to the solution suggested by you. We took the msaso15.dll of previous i.e. the Windows 7 without sp1 version and imported that. And the problem vanished. I think this means that we are still using the old msado15.dll. But as long as it works we are happy.

关于c++ - COM msado15.dll 程序已停止运行,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13170009/

相关文章:

c++ - 如何使用模板类作为参数?

c++ - 序列点 - 数组上的异或交换得到错误的结果

c# - 当目标应用程序以管理员身份运行时,ShowWindow 功能不起作用

node.js - NodeJs 安装失败,没有任何解释。这是日志

c++ - QCombobox::setView 在 Windows 7 上崩溃应用程序

c++ - 考虑到所有可能的编码,是否有将 wstring 转换为 std::string 的通用方法?

c++ - 如何使用getaddrinfo()?

c# - 在 C# 中将参数值从一个函数传递到另一个函数

c# - 在意外的时间调用了一个方法。 (HRESULT : 0x8000000E) exception was thrown by a method 的异常

visual-c++ - 使用 Windows 7 SDK 的凭据提供程序示例