Can anyone please point me in the right direction on how to create a solution template in Visual Studio 2022 that has 8 .NET 8 C# projects?
I've searched but not finding much helpful information. I'm finding stuff for one project or older versions of Visual Studio. I apologize if there is something out there but I'm not uncovering anything helpful.
Thank you!
First, you need to prepare the template file, export multiple projects in the solution as project templates, and unzip:
<TemplateData>
<Name>Wp.WPF.Core</Name>
<Description>Wp.WPF.Core</Description>
<!--图标-->
<!--<Icon>pp.ico</Icon>-->
<ProjectType>CSharp</ProjectType>
<LanguageTag>C#</LanguageTag>
<PlatformTag>EIP4.0</PlatformTag>
<ProjectTypeTag>CSharp</ProjectTypeTag>
</TemplateData>
<TemplateContent>
<ProjectCollection>
<ProjectTemplateLink ProjectName="$safeprojectname$.BLL" CopyParameters="true">
WpWpfCore\WpWpfCoreBllTemplate\MyTemplate.vstemplate
</ProjectTemplateLink>
<ProjectTemplateLink ProjectName="$safeprojectname$.DAL" CopyParameters="true">
WpWpfCore\WpWpfCoreDalTemplate\MyTemplate.vstemplate
</ProjectTemplateLink>
<ProjectTemplateLink ProjectName="$safeprojectname$.Model" CopyParameters="true">
WpWpfCore\WpWpfCoreModelTemplate\MyTemplate.vstemplate
</ProjectTemplateLink>
<ProjectTemplateLink ProjectName="$safeprojectname$.UIL" CopyParameters="true">
WpWpfCore\WpWpfCoreUilTemplate\MyTemplate.vstemplate
</ProjectTemplateLink>
</ProjectCollection>
</TemplateContent>
At this point, all configurations and modifications have been completed. Right-click the project and select "Generate" or "Regenerate"
Copy this compressed package to the root directory of the project template of vs. When creating the project, you can find the project by searching for the project name.
For details, please refer to: https://learn.microsoft.com/en-us/visualstudio/ide/how-to-create-multi-project-templates?view=vs-2022
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With