View Single Post
 
Old 05-27-2017, 09:04 AM
ewso ewso is offline Windows 10 Office 2016
Advanced Beginner
 
Join Date: Nov 2016
Posts: 80
ewso is on a distinguished road
Default remove rows without certain word

I have several rows in a document that don't contain certain words and I need to remove them all and keep only the rows with the words. The two words are WERE and WAS. The words are often pressed up against other words in the row, like this...

abcdWASabcd
abcdWEREabcd

It's ok for the rows to be like that, but I need to remove every row that doesn't contain those words. The rows are not in a table. It's just a bunch of rows of text.
Can this be done with a macro?

Thanks
Reply With Quote