Visual Studio 2019设置自定义头部注释

1、首先在VS的安装路径下找到如下几个文件夹:

C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\ItemTemplates\CSharp\Code\2052

2.分别进入这几个文件夹中,将原文件备份至其他位置,修改后进行替换即可

3.友情提供自用表头注释

using System;
using System.Collections.Generic;
$if$ ($targetframeworkversion$ >= 3.5)using System.Linq;
$endif$using System.Text;
$if$ ($targetframeworkversion$ >= 4.5)using System.Threading.Tasks;
$endif$
namespace $rootnamespace$ {

///<summary>
/// 版 本:v1.0.0
/// 创建人:万邦科技-Anthony
/// 日 期:$time$
/// 描 述:
///</summary>
public class $safeitemrootname$
{
}
}

猜你喜欢

转载自www.cnblogs.com/Anthony518/p/11016571.html