1

我一直在尝试按照说明安装 Windows SDK 附带的示例 VSS 硬件提供程序。不幸的是,COM 拒绝注册 DLL,并给出以下输出:

Unregistering the existing application...
- Create the catalog object
- Get the Applications collection
- Populate...
- Search for VssSampleProvider application...
- Saving changes...
Done.
Creating a new COM+ application:
- Creating the catalog object
- Get the Applications collection
- Populate...
- Add new application object
- Set app name = VssSampleProvider
- Set app description = VSS HW Sample Provider
- Set app access check = true
- Set encrypted COM communication = true
- Set secure references = true
- Set impersonation = false
- Save changes...
- Create Windows service running as Local System
- Add the DLL component

ERROR:
- Error code: -2146368511 [0x80110401]
- Exit code: 113
- Description:
- Source:
- Help file:
- Help context: 0
- COM+ Errors detected: (2)
   * (COM+ ERROR 0) on C:\VssSampleProvider\VssSampleProvider.dll
       ErrorCode: -2146368486 [0x8011041A]
       MajorRef: C:\VssSampleProvider\VssSampleProvider.dll
       MinorRef: invalid
   * (COM+ ERROR 1) on SampleProvider
       ErrorCode: -2146368486 [0x8011041A]
       MajorRef: {423BBC78-9B20-4BBE-A967-B63EC43BC7F3}
       MinorRef: invalid

这是该线程中描述的相同问题:

http://www.osronline.com/showthread.cfm?link=185213

我试过同时使用 x86 和 x64 机器,但没有区别。任何提示或建议都将受到欢迎。

4

2 回答 2

1

这需要 msvcr110.dll 和 msvcp110.dll。这些文件带有“Visual C++ Redistributable Packages”。您可以在以下链接中获取最新的“Visual C++ Redistributable Packages”。 http://www.microsoft.com/en-in/download/details.aspx?id=40784

于 2014-08-04T08:23:06.057 回答
-1

我最终设法解决了这个问题。事实证明,您只能在 Windows 服务器发行版上安装硬件提供程序,我使用的是普通的 Windows 7。有关 API 调用,请参阅 MSDN 页面:

http://msdn.microsoft.com/en-us/library/windows/desktop/aa381923(v=vs.85).aspx

在 Windows Server 2012 机器上编译 64 位并使用带有 SDK 的 64 位工具,它似乎可以正常工作。

于 2013-08-27T12:10:02.707 回答