View Single Post
 
Old 11-17-2025, 04:04 AM
gmaxey gmaxey is offline Windows 10 Office 2019
Expert
 
Join Date: May 2010
Location: Brasstown, NC
Posts: 1,634
gmaxey is just really nicegmaxey is just really nicegmaxey is just really nicegmaxey is just really nicegmaxey is just really nice
Default

Code:
Sub AngleQuotationMarks()
Dim iType As Long
Dim oRng As Range
  Options.AutoFormatAsYouTypeReplaceQuotes = False
  For iType = 1 To 1 '2
    On Error GoTo lbl_Exit
    Set oRng = ActiveDocument.StoryRanges(iType)
    With oRng.Find
      .ClearFormatting
      .Replacement.ClearFormatting
      .Wrap = wdFindStop
      .Format = False
      .MatchWildcards = True
      .Text = "\?" & "(^0171)"
      .Replacement.Text = "\1" & "^0187"
      .Execute Replace:=wdReplaceAll
      .Text = "\?" & "^0187"
      .Replacement.Text = "^0171" & "^0187"
      .Execute Replace:=wdReplaceAll
    End With
  Next iType
lbl_Exit:
  'Options.AutoFormatAsYouTypeReplaceQuotes = True
  Exit Sub
End Sub
__________________
Greg Maxey
Please visit my web site at http://www.gregmaxey.com/
Reply With Quote