Copy link to clipboard
Copied
Two related questions:
For example in my TOC Style dropdown (in TOC window) has listed:
My thought was if my IG TOC was marked as the master doc in the book and say other files currently had PG Style selected...that the synchronize feature would synchronize and change all of my other files setting from PG to IG. This does not seem to be the case.
Thanks for any assistance!
Julia
1. That probably could be scripted; but I don't know of an existing one.
2. Synchronizing styles will force an over-writing of document styles, as long as they have the same name. A master style of a different name does not have the human intelligence to over-write a style with a different name.
Copy link to clipboard
Copied
1. That probably could be scripted; but I don't know of an existing one.
2. Synchronizing styles will force an over-writing of document styles, as long as they have the same name. A master style of a different name does not have the human intelligence to over-write a style with a different name.
Copy link to clipboard
Copied
Gotcha! I was hoping that like Conditional Text settings that the TOC Style synchronization would match up what TOC style the master was utilizing and "flip the style used." Sounds like it just updates the style settings within the style to match between docs.
I am really surprised that InDesign Books do not have the ability to update the TOCs within the individual files. We moved from (hesistate I mention it...smirk) FrameMaker to InDesign. This was an awesome feature in Frame...that I have not been able to find some work around for in InDesign. So it sounds like unless there is a script built...I have manually update my TOCs in 25 files each time...which is not impossible...just not super efficient. Thanks for your response!
Copy link to clipboard
Copied
Hi Julia—speaking as a long-time FrameMaker and InDesign certified instructor, you are absolutely correct. It would make a good feature request: Wishform - Adobe InDesign.
Copy link to clipboard
Copied
Thanks Barb! I did not know this form was out there....it will get some use...I have a few requests:O)
Copy link to clipboard
Copied
Yay! The more who speak up, the more our voices are heard! And the InDesign team does read every one of these.
Copy link to clipboard
Copied
Hey Guys,
I did some digging and I found another old post from 2014 with the same type of request and someone had responded with a script to try. I tried it...didn't work...BUT one of my co-workers who is ADOBE AWESOME....took the script and rewrote some parts and came up with one that works. There are two versions - one that updates all TOCs from the book without closing the files and book (which is what I wanted so I could then print the book pdf once the TOCs were updated)...and one that closes everything (this was part of the original script someone else created. I will submit this also to the Wishform to see if they can build it into an upcoming version update.
Script that updates while leaving book and files open:
var myBook = app.activeBook;
for(var n=0; n < myBook.bookContents.length; n++)
{
app.open(File(myBook.bookContents
for (var i = 0; i < app.activeDocument.allPageItems.length; i++)
{
var myPageItem = document.allPageItems;
if(myPageItem.getElements()[0].constructor.name == "TextFrame")
{
myPageItem.select();
try{
app.scriptMenuActions.itemByID(71442).invoke();
}catch(e){}
}
}
}
Script that updates closing book and files once run:
var myBook = app.activeBook;
for(var n=0; n < myBook.bookContents.length; n++)
{
app.open(File(myBook.bookContents
for (var i = 0; i < app.activeDocument.allPageItems.length; i++)
{
var myPageItem = document.allPageItems;
if(myPageItem.getElements()[0].constructor.name == "TextFrame")
{
myPageItem.select();
try{
app.scriptMenuActions.itemByID(71442).invoke();
}catch(e){}
}
}
app.activeDocument.close(SaveOptions.YES);
}
app.activeBook.close(SaveOptions.YES);
Want to pass along credit to Update TOC from the Book Pane for helping get to a script solution. This post was a great starting point!