A
andreas
Dear Experts:
below macro replaces the footnote reference number in the footnotes
story with the footnote reference number and a space. Regrettably this
space has got a superscript setting. When trying to undo this
superscript setting with the code lines starting "For Each rngFoot in
ActiveDocument.Footnotes...." nothing happens. What's wrong with this
code?.
Help is appreciated. Thank you very much in advance. Regards, Andreas
Sub InsertSpaceAfterfootnote
Dim rngfoot as footnote
With ActiveDocument.StoryRanges(wdFootnotesStory).Find
..ClearFormatting
..Replacement.ClearFormatting
.Text = "(^2)"
.Replacement.Text = "\1 "
.Forward = True
.Wrap = wdFindContinue
.MatchWildcards = True
.Execute Replace:=wdReplaceAll
End With
' Comment: the following lines do nothing to the footnotes. Why?
For Each rngFoot In ActiveDocument.Footnotes
If rngFoot.range.Characters.First = Chr(32) Then
rngFoot.range.Characters.First.Font.Reset
End If
Next
End Sub
below macro replaces the footnote reference number in the footnotes
story with the footnote reference number and a space. Regrettably this
space has got a superscript setting. When trying to undo this
superscript setting with the code lines starting "For Each rngFoot in
ActiveDocument.Footnotes...." nothing happens. What's wrong with this
code?.
Help is appreciated. Thank you very much in advance. Regards, Andreas
Sub InsertSpaceAfterfootnote
Dim rngfoot as footnote
With ActiveDocument.StoryRanges(wdFootnotesStory).Find
..ClearFormatting
..Replacement.ClearFormatting
.Text = "(^2)"
.Replacement.Text = "\1 "
.Forward = True
.Wrap = wdFindContinue
.MatchWildcards = True
.Execute Replace:=wdReplaceAll
End With
' Comment: the following lines do nothing to the footnotes. Why?
For Each rngFoot In ActiveDocument.Footnotes
If rngFoot.range.Characters.First = Chr(32) Then
rngFoot.range.Characters.First.Font.Reset
End If
Next
End Sub