相关疑难解决方法(0)

使用.NET CodeDom代码生成时,如何自定义自动生成的注释?

我正在使用CodeCompileUnitCSharpCodeProvider生成一些源代码.它将下面的标题添加到所有生成的代码中.有没有办法自定义评论,所以它说了别的什么?

// <auto-generated>
//     This code was generated by a tool.
//     Runtime Version:2.0.50727.3053
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
Run Code Online (Sandbox Code Playgroud)

.net c# code-generation

13
推荐指数
1
解决办法
3183
查看次数

标签 统计

.net ×1

c# ×1

code-generation ×1