使 .NET Standard 库 COM 可见? [英] Make a .NET Standard library COM-Visible?

查看:31
本文介绍了使 .NET Standard 库 COM 可见?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于完整的 .NET 项目,您可以在 Project Properties > 中勾选一个框以使项目 COM 可见.应用程序选项卡 >装配信息..:

For a full .NET project you can tick a box to make the project COM Visible in Project Properties > Application tab > Assembly Information..:

但是,.NET Standard 项目不存在 Assembly Information.. 按钮,而是在 Project Properties > 中输入数据.包选项卡,但该选项卡没有Make Assembly COM-Visible 的复选框:

However, the Assembly Information.. button doesn't exist for .NET Standard projects, instead that data is entered on the Project Properties > Package tab, but that tab doesn't have a checkbox for Make Assembly COM-Visible:

您是否仍然可以通过其他方法使 .NET Standard 库 COM 可见,或者出于某种原因这样做没有意义?

Can you still make .NET Standard libraries COM Visible by some other method, or does it not make sense to do that for some reason?

推荐答案

我在 GitHub 上评论了您的问题.您绝对可以使 .NET Standard 库 COM 可见,前提是您选择的运行时同时支持 .NET Standard 和 COM 可见性.

I commented on your issue at GitHub. You can definitely make .NET Standard libraries COM visible, provided the runtime you choose supports both .NET Standard and COM visibility.

以下是使用 Visual Studio 2017 和 WiX 的示例:ComVisibleNetStandard

Here's an example using Visual Studio 2017 and WiX: ComVisibleNetStandard

这篇关于使 .NET Standard 库 COM 可见?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆