【问题标题】:ADO Connection CreateInstance Fails On Windows Server 2003ADO 连接 CreateInstance 在 Windows Server 2003 上失败
【发布时间】:2012-07-06 14:11:13
【问题描述】:

我有一个应用程序在 Windows 7 上运行良好,但在 Server 2003 上失败。失败的行是下面的第三行

_ConnectionPtr pConnection = NULL;
::CoInitialize(NULL);
HRESULT hr = pConnection.CreateInstance(__uuidof(Connection));

返回的 HRESULT 为 0x80004002(不支持接口)。两台机器都安装了 MDAC,我不明白为什么会出现这个错误。发生这种情况的任何原因?

【问题讨论】:

    标签: c++ ado


    【解决方案1】:

    【讨论】:

    • 这确实是问题所在,安装 Windows 更新后它现在可以工作了。谢谢。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2012-12-22
    • 2017-02-06
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2023-03-23
    相关资源
    最近更新 更多