If you need this only once, do following after opening the file:
- Press Ctrl+F to open the Find dialog.
- Enter in Find What the string word 1|string 2|word3|string4 .
- Check the option Match Case if it is not important to search not case sensitive. A case sensitive search is faster than a search ignoring the case of letters.
- Check the option Regular Expressions which is required for this search because | is a Perl regular expression character which means OR.
- Click on button Advanced if you do not already see the advanced options.
- Select the regular expression engine Perl which is the only regexp engine supporting more than 2 arguments in an OR expression.
- Check the option List Lines Containing String.
- Find Where should be set to Current File and the other 3 options should not be enabled.
- Run the search now with pressing button Next.
A dialog opens showing you the lines with one of the words / strings you entered.
- If you don't see the line numbers in this dialog, check the option Show Line Numbers in the bottom right corner of the dialog.
- Press the button Clipboard to copy what you see in the dialog to the clipboard and close the dialog with a click on button Close.
- Press Ctrl+N to open a new file and press Ctrl+V to paste into the new file the just copied lines with the line number.
That's it. If you need this often, it would be better to do the same with a script or a macro. There are already some macros and scripts for the List Lines Containing String
feature in the macro and script forums.