Comment Block Macros

Do you find that it is much easier to comment or uncomment a block of code in Visual Basic editor? I wrote a couple of macro routines to do the same for Visual C++ editor. When you select a block of code and click on CommentBlock toolbar button, the selected text will be commented out with '//'. When you click on UncommentBlock toolbar button, the selected text will be uncommented if it was commented out with '//'.

To install the macro file, download it to your Visual Studio macro directory. This is usually C:\Program Files\Microsoft Visual Studio\Common\MSDev98\Macros. From the Visual C++ editor, simply create two toolbar. Set each of them up to to run these macros: CommentBlock and UncommentBlock.

Downloads

Download source - 1 Kb


Comments

  • InterDev

    Posted by Legacy on 08/13/2002 12:00am

    Originally posted by: zk

    I guess that this macro can be used also in VS InterDev, of course tha change have to be made: instead "//" it has to be "'". I am having a trouble on how to register macro in InterDev and will apriciate some help.

    Thanks

    Reply
Leave a Comment
  • Your email address will not be published. All fields are required.

Top White Papers and Webcasts

  • Best-in-Class organizations execute on a strategy that supports the multi-channel nature of customer requests. These leading organizations do not just open up their service infrastructures to accommodate new channels, but also empower their teams to deliver an effective and consistent experience regardless of the channel selected by the customer. This document will highlight the key business capabilities that support a Best-in-Class customer engagement strategy.

  • Live Event Date: September 17, 2014 @ 1:00 p.m. ET / 10:00 a.m. PT Another day, another end-of-support deadline. You've heard enough about the hazards of not migrating to Windows Server 2008 or 2012. What you may not know is that there's plenty in it for you and your business, like increased automation and performance, time-saving technical features, and a lower total cost of ownership. Check out this upcoming eSeminar and join Rich Holmes, Pomeroy's practice director of virtualization, as he discusses the …

Most Popular Programming Stories

More for Developers

Latest Developer Headlines

RSS Feeds