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

vs2010 仿XCode风格的头注释宏的更多相关文章

  1. 论XCODE工程里使用的宏定义.

    在XCODE开发过程中,经常会遇到引用头文件,引用库路径的问题,如果不是直接的源码引入,则需要在工程中增加设置.虽然现在有了Pod这类集合管理工具,但有时为了一个很小的lib引入Pod这尊大神还是有点 ...

  2. idea如何设置类头注释和方法注释

    CSDN 2016博客之星评选结果公布      [系列直播]算法与游戏实战技术      "我的2016"主题征文活动 详细:idea如何设置类头注释和方法注释 标签: idea ...

  3. VA中用文件头注释和函数头注释Suggestions

    写C++代码,不能不用VA,这里贴两个我最常用的注释Suggestions. [1.File Header 文件头注释] /*** @file     $FILE_BASE$.$FILE_EXT$* ...

  4. xcode 预编译头文件

    xcode 预编译头文件 cocos2d-prefix.pch  #import <Foundation/Foundation.h>

  5. intellj idea 如何设置类头注释和方法注释

    intellj idea 如何设置类头注释和方法注释           intellj idea的强大之处就不多说了,相信每个用过它的人都会体会到,但是我们也会被他的复杂搞的晕头转向,尤其刚从ecl ...

  6. IntelliJ IDEA 如何设置类头注释和方法注释

    从VS转过来的,ide的差距很大的,所以...特意折腾了很久,结果还是没有VS的 '///' 好用 一.类头注释 打开file -> setting -> Editor -> Fil ...

  7. Visual Studio+VAssistX自动添加注释,函数头注释,文件头注释

    转载:http://blog.csdn.net/xzytl60937234/article/details/70455777 在VAssistX中为C++提供了比较规范注释模板,用这个注释模板为编写的 ...

  8. Unity VS 创建脚本自动添加头注释-时间-描述-作者等信息

    Unity生成脚本自动添加头注释 本文提供全流程,中文翻译. Chinar 坚持将简单的生活方式,带给世人!(拥有更好的阅读体验 -- 高分辨率用户请根据需求调整网页缩放比例) Chinar -- 心 ...

  9. IDEA设置头注释—自定义author和date

    IDEA设置头注释,自定义author和date的方法如下所示: 去掉波浪线的方式:鼠标选中单词 --> 点击鼠标右键 --> spelling --> save 'xxx' to ...

随机推荐

  1. mysql运行参数详解

    1, 查看MySQL服务器配置信息 mysql> show variables; 2, 查看MySQL服务器运行的各种状态值 mysql> show global status; 3, 慢 ...

  2. Java final,static 关键字

    final关键字: 这是无法改变的”或者“终态的”含义,它可以修饰非抽象类.非抽象类成员方法和变量. final类不能被继承,没有子类,final类中的方法默认是final的.final方法不能被子类 ...

  3. Python模块(scapy)

    scapy scapy相当于linux的tcpdump的功能

  4. 第七篇 Integration Services:中级工作流管理

    本篇文章是Integration Services系列的第七篇,详细内容请参考原文. 简介在上一篇文章,我们创建了一个新的SSIS包,学习了SSIS中的脚本任务和优先约束,并检查包的MaxConcur ...

  5. iOS 图片循环滚动(切片效果)

                             #import <UIKit/UIKit.h> @interface AppDelegate : UIResponder <UIAp ...

  6. pip报ssl错误解决

     InsecurePlatformWarning: A true SSLContext object is not available.   # yum -y install openssl-deve ...

  7. git客户端

    https://git-for-windows.github.io/ http://blog.csdn.net/shulianghan/article/details/18812279 自己的gith ...

  8. leetcode96 Unique Binary Search Trees

    题目: Given n, how many structurally unique BST's (binary search trees) that store values 1...n? For e ...

  9. Lintcode: Recover Rotated Sorted Array

    Given a rotated sorted array, recover it to sorted array in-place. Example [4, 5, 1, 2, 3] -> [1, ...

  10. fzu 2146 Easy Game

    http://acm.fzu.edu.cn/problem.php?pid=2146  Problem 2146 Easy Game Accept: 661    Submit: 915Time Li ...