View Single Post
 
Old 12-02-2019, 11:41 AM
thiagoafdoria thiagoafdoria is offline Windows 10 Office 2019
Novice
 
Join Date: Feb 2017
Posts: 18
thiagoafdoria is on a distinguished road
Default

Thank you very much, macropod!

For those whose are interested, the final result is this:

Code:
Sub Demo 2 ( )
Application.ScreenUpdating = False
With ActiveDocument.Range.Find
  .ClearFormatting
  .Replacement.ClearFormatting
  .Format = True
  .Forward = True
  .MatchWildcards = True
  .Wrap = wdFindContinue
  .Replacement.Text = "\1"
  .Text = "\*\*([!\*]@)\*\*"
  .Replacement.Font.Bold = True
  .Execute Replace:=wdReplaceAll
  .Replacement.ClearFormatting
  .Text = "\__(*)\__"
  .Replacement.Font.Italic = True
  .Execute Replace:=wdReplaceAll
End With
Application.ScreenUpdating = True
End Sub
Reply With Quote