简体   繁体   English

如何创建Visual Studio 2017多模板VSIX项目?

[英]How to create Visual Studio 2017 multi template VSIX project?

I'm trying to create an VSIX extension with Visual Studio 2017. My idea is that this extension can contain more than one template inside, It means that with one vsix installer, I want to install more than one template in Visual Studio (something like Prism Template pack). 我正在尝试使用Visual Studio 2017创建VSIX扩展。我的想法是,此扩展可以在内部包含多个模板,这意味着通过一个vsix安装程序,我想在Visual Studio中安装多个模板(类似棱镜模板包)。

I have the next scenario: 我有下一个场景:

Two C# template project and one VSIX Project. 两个C#模板项目和一个VSIX项目。

在此处输入图片说明

In the asset section of VSIX project, I'm referencing the output of my two template project: 在VSIX项目的资产部分,我引用了两个模板项目的输出:

在此处输入图片说明

But when I search them in Visual Studio for looking if they are installed, there is only one of them: 但是,当我在Visual Studio中搜索它们以查看它们是否已安装时,只有其中之一: 在此处输入图片说明

Both template project have same category, so it suppose they have to be in same folder. 两个模板项目都具有相同的类别,因此假定它们必须位于同一文件夹中。

Is there any configuration or something I'm missing to achieve the behavior I described? 是否有任何配置或某些我无法实现的功能?

Thanks in advance 提前致谢

I finally did make it work. 我终于做到了。 It was my mistake: 这是我的错误:

The template project were on different folder, but the output filename was the same, so, when the VSIX project was compiled overwrite the file and only showed one of them. 模板项目位于不同的文件夹中,但是输出文件名相同,因此,在编译VSIX项目时,将覆盖文件并仅显示其中之一。

My solution was giving one unique name for each template project and that's all. 我的解决方案是为每个模板项目提供一个唯一的名称,仅此而已。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 多项目模板Visual Studio 2017 - Multi project template Visual Studio 2017 VSIX Visual Studio 扩展项目模板创建 - VSIX Visual studio extension project template Creation 如何在 Visual Studio 2013 中创建多项目模板? - How to create a multi project template in visual studio 2013? 如何在Visual Studio 2017 VSIX C#项目中启用/禁用命令 - How can I enable/disable command in Visual Studio 2017 VSIX C# project Visual Studio 2017:创建项目模板>使用它>所有引用都损坏了? - Visual Studio 2017: Create project template > use it > all references broken? 项目模板DTE Visual Studio 2017 nuget - Project Template DTE Visual Studio 2017 nuget 通过 Visual Studio 2017 VSIX 项目构建 SQL Server Management Studio 扩展:为 AsyncPackage 类绕过 Initialiaze() - Building a SQL Server Management Studio Extension via Visual Studio 2017 VSIX project: Bypass Initialiaze() for AsyncPackage class 如何在 vsix 项目中获取和使用 Visual Studio 命令 - How to get and use Visual Studio command in vsix project 如何在重命名 Visual Studio 项目 (VSIX) 时收到通知? - How to get notified when a Visual Studio project is renamed (VSIX)? 使用MEF和VSIX创建Visual Studio项目系统 - Creating Visual Studio project system with MEF and VSIX
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM