View Single Post
 
Old 10-06-2021, 07:49 PM
Guessed's Avatar
Guessed Guessed is offline Windows 10 Office 2016
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 4,158
Guessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant future
Default

Like this
Code:
Sub MFindReplace()
  Dim aDoc As Document, strFindText As String, strReplaceText As String
  strFindText = "Finders"
  strReplaceText = "Keepers"
  For Each aDoc In Application.Documents
    With aDoc.Range.Find
      .Text = strFindText
      .Replacement.Text = strReplaceText
      .Forward = True
      .Wrap = wdFindContinue
      .Format = False
      .MatchCase = False
      .MatchWholeWord = False
      .MatchWildcards = False
      .MatchSoundsLike = False
      .MatchAllWordForms = False
      .Execute Replace:=wdReplaceAll
    End With
  Next aDoc
End Sub
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote