开发者

Project template with three projects?

Is it possible to create a project template containing three projects?

I've built a sample project for my client which contains the basic structure for all their new applications. It would be sweet to be able to create a project template 开发者_如何学编程from it to make everything a lot easier.

Projects in the solution

  • ProjectName.Abstractions
  • ProjectName.Services
  • ProjectName.WebClient

What I really would like is a solution template =)


There are no solution templates, but there are multi-project templates:

http://msdn.microsoft.com/en-us/library/ms185308(v=VS.100).aspx


If you want to create a solution which contains three project as above. Just follow method of creating multi-project template.

And then in .csproj file of main project, replace

<ProjectReference Include="\ProjectName.Services\ProjectName.Services.csproj">
      <Project>{7D31A904-BA57-4CDA-XXXX-XXXXXXXXXXX}</Project>
      <Name>ProjectName.Services</Name>
    </ProjectReference>

with below code,

<ProjectReference Include="\$safeprojectname$.Services\$safeprojectname$.Services.csproj">
      <Project>{7D31A904-BA57-4CDA-XXXX-XXXXXXXXXXX}</Project>
      <Name>$safeprojectname$.Services</Name>
    </ProjectReference>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜