Search code examples
notepad++

Notepad++ - delete all lines with certain text


I have notepad++ 5.8.2 and I was trying to remove all lines starting with 'Processed XXXXX total records' where XXXXX is a various number.
I tried to CTRL+H and put 'Processed.$ in Find what selecting Regular Expression and putting blank in Replace with but it doesn't even find those lines Processed. Did I do something wrong in regex expression to find and replace them?


Solution

  • This will help you:

    1. Press CTRL + H
    2. Select Regular Expression at the bottom
    3. Find ^Processed \d+ total records.*?
    4. Click Replace All

    After, you may want to clean all the blank lines:

    1. Find ^\s*
    2. Click Replace All