Whats the 'parent' of a footnote?
Dear friends and wizards!
You all do know how to traverse the universe of footnotes in a document:
oFn = oDoc.FirstFnInDoc;
while (oFn.ObjectValid () === 1) {
// do stuff
}
oFn = oFn.NextFnInDoc;
}
With this method (and also with the Find method) I get footnotes from various environments:
- from the main flow
- from table cells (table footnotes)
- from a textframe within an anchored frame
- from a textframe within an anchored frame within a table cell
How can I find out, what's the 'parent environment' of a footnote is (to be precise: it's anchor object)?
I have not found something useful to determine this, because a particular function I want to script should work only on the ones mentioned first: the plain ordinary footnote.
For the curious: The task is to convert footnotes to endnotes.
Any ideas are highly welcome!
Edit
Do You think this could be useful:
Loop through the paragraphs and check whether there is a footnote anchor in it
IMHO the paragraphs are then only from the main flow, not from text cells or nested text frames.

