zoukankan      html  css  js  c++  java
  • vs2010 仿XCode风格的头注释宏

    Sub DocumentFileHeader()

    Dim star As String
    star = "//******************************************************************************"

    ' 将添加焦点定位在文件首部
    DTE.ActiveDocument.Selection.StartOfDocument()

    ' 添加一个版权说明
    'DTE.ActiveDocument.Selection.Text = star
    DTE.ActiveDocument.Selection.NewLine()
    DTE.ActiveDocument.Selection.Text = "// "
    DTE.ActiveDocument.Selection.NewLine()
    DTE.ActiveDocument.Selection.Text = "// " + DTE.ActiveDocument.Name
    DTE.ActiveDocument.Selection.NewLine()
    DTE.ActiveDocument.Selection.Text = "// "
    DTE.ActiveDocument.Selection.NewLine()
    DTE.ActiveDocument.Selection.Text = "// " + String.Format("Created by {0} on {1:D}.", "***", Date.Now.ToString("yy-MM-dd"))
    DTE.ActiveDocument.Selection.NewLine()
    DTE.ActiveDocument.Selection.Text = "// " + String.Format("Copyright (c) {0}年 {1}. All rights reserved.", Date.Now.Year,"***")
    DTE.ActiveDocument.Selection.NewLine()
    DTE.ActiveDocument.Selection.Text = "// "
    DTE.ActiveDocument.Selection.NewLine()
    'DTE.ActiveDocument.Selection.Text = star
    DTE.ActiveDocument.Selection.NewLine()
    End Sub

  • 相关阅读:
    Java 测试代码模板
    git 保存用户名和密码
    git 高级命令
    git 最常用命令
    git 冲突解决
    git diff命令
    nginx静态服务器的配置
    使用SFTP工具下载文件
    git log 格式化输出
    9-angular.fromJson
  • 原文地址:https://www.cnblogs.com/msdynax/p/3615936.html
Copyright © 2011-2022 走看看