Skip to main content
New Participant
February 27, 2024
Answered

Index - any scripts to automate tagging?

  • February 27, 2024
  • 3 replies
  • 1687 views

Hi all,

I've been working on indexing several documents, and am trying to find out if there are any scripts or other methods out there to automate the process. It would be so much easier if you could give InDesign a full list of terms and it will automatically tag them for the index, rather than finding and tagging each manually.

I did find a few scripts but they seem to be for much older versions.

I don't know anything about creating scripts myself.

Any leads/advice welcome! thanks!

This topic has been closed for replies.
Correct answer brian_p_dts

This eschews the normal index feature, but will generate an index from a word list

 

https://creativepro.com/files/kahrel/indesign/index_from_wordlist.html

3 replies

New Participant
February 28, 2024

I tried out the script, and it does indeed work! Yay!
Unfortunately it wipes out any exisitng index tagging so won't work on this particular project, but will on any that I'm starting an index from scratch.

So, solved! Thanks a bunch

Robert at ID-Tasker
Brainiac
February 28, 2024

@P28476046v7uw

 

You need to change to "false" this:

 

// Replace index?

 var replace_index = true ;

 

brian_p_dts
brian_p_dtsCorrect answer
Adobe Expert
February 27, 2024

This eschews the normal index feature, but will generate an index from a word list

 

https://creativepro.com/files/kahrel/indesign/index_from_wordlist.html

Robert at ID-Tasker
Brainiac
February 27, 2024

@brian_p_dts, @P28476046v7uw 

 

But @Peter Kahrel's script is adding topics and references using built-in Index mechanism?

 

brian_p_dts
Adobe Expert
February 28, 2024
quote

No it doesn't. 


By @brian_p_dts

 

I'm sorry, but have you seen the code? 

 

Or my understanding of JavaScript is so bad?

 

... 

new_topic = docs[i].indexes[0].topics.add (word_list[j]);

... 

new_topic.pageReferences.add (found[k], PageReferenceType.currentPage);

... 

 


Ah, had been a while since I actually used it. I thought it eschewed it. Or I may be thinking of another one of his. My bad.

New Participant
February 27, 2024

so, from the sounds of it, there's no simple solution?
Or, you can add the terms, but still have to run the "add all" for each term separately?

Note that I need to work with the InDesign index generator so that all the links and such will work for ebooks/ehanced PDF.

Robert at ID-Tasker
Brainiac
February 27, 2024

Do you work on Mac or a PC?