XRngFind.HighlightColorIndex = wdBrightGreenģ. If xRngFind.HighlightColorIndex wdYellow Then Options.DefaultHighlightColorIndex = wdYellow VBA code: Find and highlight the duplicate paragraphs in Word document: Sub highlightdup() And then, click Insert > Module, copy and paste below code into the opened blank module: Hold down the ALT + F11 keys to open the Microsoft Visual Basic for Applications window.Ģ.
To find and highlight the duplicate paragraphs in a Word document, the following VBA code can do you a favor, please do as this:ġ.
How could you find and highlight the duplicate paragraphs quickly and easily in Word document?įind and highlight the duplicate paragraphs in Word document with VBA code Supposing, you have a large Word document which may have hundreds of pages, now, you want to check if there are duplicate paragraphs and then highlight to make them outstanding, so that you can deal with the duplicate sentences. How to find and highlight duplicate paragraphs in Word document?