- 创建一个新的控制台应用程序.
- 将文件编辑为您想要的新文件.
- 在文件"菜单中选择导出模板...".
- 遍历向导(为新模板选择名称,等等)
- 确保已选中自动将模板导入Visual Studio".
- 重新启动VS
- 选择新项目"
- 在左侧的树形控件中选择"Visual C ++"
- 在中间的列表中选择您的新模板
- 新项目中常用的东西(项目的名称和位置等)
- Create a new console application.
- Edit the file to be as you want it in the new one.
- Select "Export Template..." in the "File" menu.
- Walk through the wizard (choose a name for your new template, etc.)
- Be sure the "Automatically import the template into Visual Studio" is checked.
- Restart VS
- Select "New Project"
- Select "Visual C++" in the tree control on the left
- Select your new template in the list in the middle
- The usual new-project stuff (name and location for the project, etc.)
[注意:在撰写本文时,我正在VS 2013中进行查看.我不记得它在VS 2015中有所变化,但是有可能.]
[Note: As I'm writing this, I'm looking at it in VS 2013. I don't recall it's changing in VS 2015, but it's possible.]