views:

37

answers:

1

Every once in a while, my code gets littered with many useless comments, most of them are obsolete lines of code, and some are obsolete "memos to self".
So I was wondering if there's a way to just select a code section, and with some magic key combination or macro, delete all of those.

Thanks.

+1  A: 

I believe the search & replace in VS allows for regular expressions, it would be easy enough to search for "// (anything to end of line" or "/* (anything) */" and replace with "".

Marc Bernier
How didn't I think about that (-:
Oren A