Endnotes in a separate document

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello
Is there any way to place endnotes in a separate document rather than at the end of the document?
Thanks for any input you can offer
 
This is an untested modification of a macro that converted endnotes to
ordinary text at the end of a document:

Dim aendnote As Endnote, Source As Document, Target As Document
Set Source = ActiveDocument
Set Target = Documents.Add
For Each aendnote In Source.Endnotes
Target.Range.InsertAfter vbCr & aendnote.Index & vbTab &
aendnote.Range
aendnote.Reference.InsertBefore "a" & aendnote.Index & "a"
Next aendnote
For Each aendnote In Source.Endnotes
aendnote.Reference.Delete
Next aendnote
Source.Activate
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find.Replacement.Font
.Superscript = True
End With
With Selection.Find
.Text = "(a)([0-9]{1,})(a)"
.Replacement.Text = "\2"
.Forward = True
.Wrap = wdFindContinue
.Format = True
.MatchWildcards = True
End With
Selection.Find.Execute Replace:=wdReplaceAll

Here is the original macro

' Macro created 29/09/99 by Doug Robbins to replace endnotes with textnotes
at end of document
' to replace the endnote reference in the body of the document with a
superscript number.
'
Dim aendnote As Endnote
For Each aendnote In ActiveDocument.Endnotes
ActiveDocument.Range.InsertAfter vbCr & aendnote.Index & vbTab &
aendnote.Range
aendnote.Reference.InsertBefore "a" & aendnote.Index & "a"
Next aendnote
For Each aendnote In ActiveDocument.Endnotes
aendnote.Reference.Delete
Next aendnote
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find.Replacement.Font
.Superscript = True
End With
With Selection.Find
.Text = "(a)([0-9]{1,})(a)"
.Replacement.Text = "\2"
.Forward = True
.Wrap = wdFindContinue
.Format = True
.MatchWildcards = True
End With
Selection.Find.Execute Replace:=wdReplaceAll


--
Please post any further questions or followup to the newsgroups for the
benefit of others who may be interested. Unsolicited questions forwarded
directly to me will only be answered on a paid consulting basis.
Hope this helps
Doug Robbins - Word MVP
 
I sincerely appreciate your reply, Mr. Robbins
Both of your macros worked like a champ, though strangely, all my endnotes numbered 10 and higher appear with the letter 'a' preceeding and following the note. This only appeared when I ran the macros on my Mac (OS X.3 running Office:Mac v.X service release 1), on the PCs in my office it works fine. This is a minor thing for me, I can easily remove them on my own, I'm just so happy now to be able to get these endnotes into another document.
Thanks for your hel
 
Back
Top