W
Wahala
Sub FormatEraseParagraph()
'
' FormatEraseParagraph Macro
'
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find
.Text = "^p"
.Replacement.Text = " "
.Selection
.Forward = True
.Wrap = wdFindContinue
.Format = False
.MatchCase = False
.MatchWholeWord = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
Selection.Find.Execute Replace:=wdReplaceAll
End Sub
I need this macro to work on the paragraph that I have Selected
(highlighted) in the Word document. However, when I run this macro, it works
on the whole document EXCEPT what I have selected. Can you fix it for me?
'
' FormatEraseParagraph Macro
'
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find
.Text = "^p"
.Replacement.Text = " "
.Selection
.Forward = True
.Wrap = wdFindContinue
.Format = False
.MatchCase = False
.MatchWholeWord = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
Selection.Find.Execute Replace:=wdReplaceAll
End Sub
I need this macro to work on the paragraph that I have Selected
(highlighted) in the Word document. However, when I run this macro, it works
on the whole document EXCEPT what I have selected. Can you fix it for me?