您好, 我正在尝试添加对C#项目的引用。引用从TLB文件导入。我做"添加参考/浏览"并指定所需的TLB文件。在我点击"确定"后,VS2017向我显示以下消息:"对< file name>的引用;无法添加。确保该文件可访问,并且它是有效的程序集或COM组件。当我用OleView打开相同的文件时,我可以看到从这个类型库生成的有效IDL。我在这里缺少什么? 有问题的TLB可以在以下链接找到:
Hello, I am trying to add a reference to a C# project. The reference is imported from a TLB file. I do "Add reference/Browse" and specify the required TLB file. After I hit "OK", VS2017 shows me the following message: "A reference to <file name> could not be added. Make sure that the file is accessible, and that it is a valid assembly or COM component." When I open the same file with OleView, I can see a valid IDL generated from this type library. What am I missing here? The TLB in question can be found at the link below:
1drv.ms/u/s!AkX9Ou21NcEig9FcEVdnTnjXKbVcOg
1drv.ms/u/s!AkX9Ou21NcEig9FcEVdnTnjXKbVcOg
推荐答案
一个TLB是一个COM解决方案,它有助于访问COM DLL。它不是集会,它不是.NET解决方案,也不是.NET项目。 A TLB is a COM solution, which helps to access a COM DLL. it not an assembly, it's not a .NET solution and it is not a .NET project.
更多推荐
VS2017无法添加对C#项目的引用。
发布评论