It is really very simple. Just replace Selection with the range you want to find in. For example ActiveDocument.Content which is the same as the MainStory:
Code:
Sub ReplaceSuperscript()
With ActiveDocument.Content.Find
.ClearFormatting
With .Font
.Superscript = True
.Subscript = False
End With
.Replacement.ClearFormatting
With .Replacement.Font
.Superscript = False
.Subscript = False
End With
.Text = "[!^02]"
.Replacement.Text = ""
.Forward = True
.Wrap = wdFindContinue
.Format = True
.MatchCase = False
.MatchWholeWord = False
.MatchAllWordForms = False
.MatchSoundsLike = False
.MatchWildcards = True
.Execute Replace:=wdReplaceAll
End With
End Sub
If you need to replace throughout the entire document:
Code:
Sub ReplaceSuperscript()
Dim story As Range
For Each story In ActiveDocument.StoryRanges
With story.Find
.ClearFormatting
With .Font
.Superscript = True
.Subscript = False
End With
.Replacement.ClearFormatting
With .Replacement.Font
.Superscript = False
.Subscript = False
End With
.Text = "[!^02]"
.Replacement.Text = ""
.Forward = True
.Wrap = wdFindContinue
.Format = True
.MatchCase = False
.MatchWholeWord = False
.MatchAllWordForms = False
.MatchSoundsLike = False
.MatchWildcards = True
.Execute Replace:=wdReplaceAll
End With
Next story
End Sub