Events
May 19, 6 PM - May 23, 12 AM
Calling all developers, creators, and AI innovators to join us in Seattle @Microsoft Build May 19-22.
Register todayThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Specifies the organization and contents of multi-project templates.
<VSTemplate> <TemplateContent> <ProjectCollection>
<ProjectCollection>
<ProjectTemplateLink> ... </ProjectTemplateLink>
<SolutionFolder> ... </SolutionFolder>
</ProjectCollection>
The following sections describe attribute, child elements, and parent elements.
None.
Element | Description |
---|---|
ProjectTemplateLink | Optional element. Specifies a project in a multi-project template. |
SolutionFolder | Optional element. Groups projects in multi-project templates. |
Element | Description |
---|---|
TemplateContent | Required element. Specifies the contents of the template. |
Multi-project templates act as containers for two or more projects. The ProjectCollection
element is used to specify the projects to contain in the template. For more information on multi-project templates, see How to: Create multi-project templates.
This example shows a simple multi-project root .vstemplate file. In this example, the template contains two projects, My Windows Application
and My Class Library
. The ProjectName
attribute on the ProjectTemplateLink
element sets the name for Visual Studio to assign this project. If the ProjectName
attribute does not exist, the name of the .vstemplate file is used as the project name.
<VSTemplate Version="3.0.0" Type="ProjectGroup"
xmlns="http://schemas.microsoft.com/developer/vstemplate/2005">
<TemplateData>
<Name>Multi-Project Template Sample</Name>
<Description>An example of a multi-project template</Description>
<Icon>Icon.ico</Icon>
<ProjectType>VisualBasic</ProjectType>
</TemplateData>
<TemplateContent>
<ProjectCollection>
<ProjectTemplateLink ProjectName="My Windows Application">
WindowsApp\MyTemplate.vstemplate
</ProjectTemplateLink>
<ProjectTemplateLink ProjectName="My Class Library">
ClassLib\MyTemplate.vstemplate
</ProjectTemplateLink>
</ProjectCollection>
</TemplateContent>
</VSTemplate>
Events
May 19, 6 PM - May 23, 12 AM
Calling all developers, creators, and AI innovators to join us in Seattle @Microsoft Build May 19-22.
Register today