![]() |
|
#4
|
||||
|
||||
|
Based on your attachment, the following macro should be enough to repair the footnotes and their references. That said, your attachment seems to have other issues as well. For example, the body text has the 'Header' Style applied, but that's been completely overwritten with a different set of formatting.
Code:
Sub RepairFootnotes()
Application.ScreenUpdating = False
Dim FtNt As Footnote, Rng As Range
With ActiveDocument
Application.OrganizerCopy Source:=.AttachedTemplate.FullName, _
Destination:=.FullName, Name:=.Styles(wdStyleFootnoteReference).NameLocal, Object:=wdOrganizerObjectStyles
Application.OrganizerCopy Source:=.AttachedTemplate.FullName, _
Destination:=.FullName, Name:=.Styles(wdStyleFootnoteText).NameLocal, Object:=wdOrganizerObjectStyles
For Each FtNt In .Footnotes
With FtNt
With .Reference
Set Rng = .Duplicate
Rng.Collapse wdCollapseStart
Do While .Characters.Last.Next.Style <> wdStyleFootnoteReference
Rng.FormattedText = .Characters.Last.Next.FormattedText
Rng.Collapse wdCollapseEnd
.Characters.Last.Next.Text = ""
Loop
.Characters.Last.Next.Text = ""
FtNt.Reference.Style = wdStyleFootnoteReference
End With
With .Range
.Style = wdStyleFootnoteText
.Font.Reset
.ParagraphFormat.Reset
.Characters.First.Style = wdStyleFootnoteReference
End With
End With
Next
End With
Application.ScreenUpdating = True
End Sub
For Mac macro installation & usage instructions, see: Word:mac - Install a Macro
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
How to change superscript footnotes into genuine Word footnotes
|
Knounte29 | Word VBA | 41 | 01-16-2020 04:48 PM |
| Formatting issues (numbering and other issues) in big document. Possibly corrupted. Can anyone help? | Ida | Word | 9 | 07-26-2018 10:22 AM |
| Footnotes/Citations not superscript | wordquery | Word | 3 | 04-12-2017 01:55 PM |
How can I get line numbering in footnotes
|
wordhelp321 | Word | 1 | 05-19-2014 03:12 PM |
Numbering issues in Word
|
RickMayo | Word | 2 | 01-21-2013 12:16 PM |