Friday, 20 November 2015

How to remove line numbers from the copy pasted code in Notepad++

Hope many of us faced this issue while copy pasting the code. Along with the code, the line numbers will also be pasted. There are many ways to remove this line numbers from the code. In Notepad++, We can use regex ^\d+ in the Find and Replace option. But there is another handy way which is explained below.

Let's say we have a html code as below: 

1: <html>
2: <body>
3: <h1> HELLO PROGRAMMER </h1>
4: </body>
5: </html>

If We wish to remove the line numbers from 1 to 5, there is a handy way for this. Press the <Alt> key and Drag the mouse on the numbers with the left mouse button pressed. This will select the numbers alone. Thus we can delete the numbers easily with this feature in Notepad++.

1 comment: