May 2009 Entries

Removing line numbers from code pasted into Visual Studio

This is mostly for my own reference, but I'm sure others on the Interwebs might find this useful as well. If, per chance, you find yourself pasting a large amount of code into Visual Studio that, for whatever reason, has line numbers included in the copied data, one can easily remove the line number's using Visual Studio's Find & Replace with the "Use Regular Expressions" option... The trick, obviously is the RegEx, which is: ^ *:d+\: Make sure the Match case and Match whole word options are disabled and that the Replace with text box is empty, and you're good to go!

posted @ Friday, May 01, 2009 11:29 AM | Feedback (1)