Commenting out a block of code in VS2005

D

Dennis

How do you comment out a block of VB.Net code in VS2005? It seems to me
in an earlier version of VS I just ran the CommentRegion macro from the
Macro Explorer. But in VS2005 that does nothing.
 
T

Tom Shelton

How do you comment out a block of VB.Net code in VS2005? It seems to me
in an earlier version of VS I just ran the CommentRegion macro from the
Macro Explorer. But in VS2005 that does nothing.

Comment:
Higlight code, Ctrl-K,Ctrl-C

Uncomment:
Highlight code, Ctrl-K,Ctrl-U

There's also a button in the text editor toolbar :)
 
T

Tom Shelton

Edit Menu > Advanced > Comment Selection- Hide quoted text -

- Show quoted text -

another possible way, but a lot more work then just using the
keyboard :)
 
K

kimiraikkonen

another possible way, but a lot more work then just using the
keyboard :)

And another way would be:
Press "home" button that brings you to beginning of code line then put
a apostrophe :) Same way to remove.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top