P
Philologist
I am writing an academic book with endnotes. I want the headers of the pages
where the endnotes appear to have headers like the following:
[177] Notes for pages 55-57
Note for page 88 [183]
To achieve this result, I have written and tested a macro that does the
following:
1. Puts a bookmark just before every endnote.reference in the main text.
2. Inserts a text integer equal to the page number cross-reference to each
bookmark at the start of each endnote.range (e.g. "(p. 4) "). The integers
are all marked with a character style "special."
3. Copies each the endnote.index and endnote.range in order as regular text
to a
new file.
4. Closes the original file without saving changes.
I can then change the starting page number of the new file and use If and
Styleref fields in the headers (first, even, and odd) to pick up the first
and last stylized integers on each page and construct the proper header text.
I am unhappy with this solution for three reasons:
1. If the original file is changed in any way that alters pagination or
endnote count, the macro must be run again.
2. The body of the endnote must contain the cross-reference information
since hiding it also hides the Styleref field result.
3. The pagination of the new file must be adjusted manually because (a) the
explicit cross-references occasionally throw off the line breaks, and (b)
Word apparently inserts an undocumented one or two points before and/or after
each paragraph in endnote text when the interface displays it.
I am afraid my little kludge (or some variation on it) is the only way
around this problem. Does anyone know a better way? If so, what is it?
where the endnotes appear to have headers like the following:
[177] Notes for pages 55-57
Note for page 88 [183]
To achieve this result, I have written and tested a macro that does the
following:
1. Puts a bookmark just before every endnote.reference in the main text.
2. Inserts a text integer equal to the page number cross-reference to each
bookmark at the start of each endnote.range (e.g. "(p. 4) "). The integers
are all marked with a character style "special."
3. Copies each the endnote.index and endnote.range in order as regular text
to a
new file.
4. Closes the original file without saving changes.
I can then change the starting page number of the new file and use If and
Styleref fields in the headers (first, even, and odd) to pick up the first
and last stylized integers on each page and construct the proper header text.
I am unhappy with this solution for three reasons:
1. If the original file is changed in any way that alters pagination or
endnote count, the macro must be run again.
2. The body of the endnote must contain the cross-reference information
since hiding it also hides the Styleref field result.
3. The pagination of the new file must be adjusted manually because (a) the
explicit cross-references occasionally throw off the line breaks, and (b)
Word apparently inserts an undocumented one or two points before and/or after
each paragraph in endnote text when the interface displays it.
I am afraid my little kludge (or some variation on it) is the only way
around this problem. Does anyone know a better way? If so, what is it?