Jun 01 2024 12:41 PM
How do I batch delete entire pages containing a specific word or can I find multiple pages with specific word to extract the entire page? Thanks!
Jun 05 2024 04:26 AM
@Jin_Quan1010 Use a macro containing the following code
Dim strFind As String
strFind = InputBox("insert the word to be found")
Selection.HomeKey wdStory
With Selection.Find
Do While .Execute(FindText:=strFind, Forward:=True, _
MatchWildcards:=False, Wrap:=wdFindStop, MatchCase:=True) = True
ActiveDocument.Bookmarks("\page").Range.Delete
Loop
End With