【问题标题】:How to build a interop dll from the UIAutomationClient.dll如何从 UIAutomationClient.dll 构建互操作 dll
【发布时间】:2013-08-06 11:54:16
【问题描述】:

我想从现有的 UIAutomationClient.dll 4.0 版创建/构建互操作 dll。 我尝试通过以下命令使用 TlbImp.exe:

TlbImp.exe path\UIAutomationClient.dll out:Interop.UIAutomationClient.dll

但我收到以下错误消息:

Microsoft (R) .NET Framework 类型库到程序集转换器 4.0.4013 版权所有 (C) Microsoft Corporation。保留所有权利。

TlbImp : 错误 TI0000 : 输入文件 'C:\Users\patrick\Desktop\UIAutomationCli ent.dll' 不是有效类型 图书馆。

是否有另一种方法来创建互操作 dll 或解决此错误?

【问题讨论】:

  • 什么是“UIAutomation.dll”?
  • 它是你需要使用 Mircosoft UI 自动化框架的 dll,VS->Add reference->.NEt->UIAutomationClient.dll 但我需要这个 dll 的 Intertop
  • 如果您谈论的是 UIAutomationClient.dll 而不是 UIAutomation.dll,那么请先解决您的问题。 UIAutomationClient 已经是一个 .NET 程序集。
  • 是的,对不起,我的意思是 UIAutomationClient.dll #fixed
  • 所以您的意思可能是 UIAutomationCore.dll,而不是 UIAutomationClient.dll。在 UIAutomationCore.dll 上运行 TLBIMP 将创建一个 UIAutomationClient.dll(与 .NET 无关...)

标签: dll interop ui-automation


【解决方案1】:

它存在于您机器上的 VS 安装目录的 Common7\IDE\PublicAssemblies 子目录中。它具有 Microsoft 版权,并且不属于可再分发文件的一部分,因此即使它不包含任何代码,仅制作副本也有点不确定。

您可以通过在 c:\windows\syswow64\uiautomationcore.dll 上运行 Tlbimp.exe 来创建自己的。在 32 位操作系统上使用 system32。

你应该想知道你依赖它的原因。

【讨论】:

    猜你喜欢
    • 2017-12-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2013-12-16
    • 1970-01-01
    • 2011-03-19
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多