Copy link to clipboard
Copied
I have approx 30 chapters in a book and each chapter contains endnotes.
I want to accumulate all the endnotes at the end of the book and not at the end of the chapter.
I have copy pasted the end notes in a text frame and all the numbers have changed to <?>
I am trying to write a script which will convert the <?> back to numbers
Here is the copy of the script:
d = app.documents[0];
app.findGrepPreferences = null;
app.findGrepPreferences.findWhat = '~F';
fn = d.findGrep();
//alert(fn.length);
// Get a handle on the story's text frames
frames = fn[0].parentStory.textContainers;
for (i = frames.length-1; i >= 0; i--)
{
notes = frames[i].footnotes.everyItem().getElements();
}
I have no clue to to put the numbers at the beginning of the line thus replacing <?>
Any help would be appreciated.
Thanks.
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Copy link to clipboard
Copied
I tried the script.
It worked like a charm, however, it could not remove <?> sign. I had to remove it manually.
Thanks for the help.
Copy link to clipboard
Copied
> it could not remove <?> sign
I'll look into it.