Site logo

Batch Create Cross-References

Script for InDesign CS4-5 (Mac and Windows). Version 3.2.

Creates cross-references and places inline graphics in the indd-files located in the selected folder. (Sort of mini-contents at the top of each chapter of EPUBs ).
You can't use it as it is since it was written according to my client's specific requirements, but it can give you idea of how to write your own script. Or you can rework it to your needs.

Folder structure required by the script

All InDesign files should be located in one folder and images in its subfolder called “images”

The user runs the script and chooses settings ...

... and the folder to be processed

The script opens each document inserts an image at the top of the first page (if a jpg-file with name matching the name of the indd-file exists in the “images” folder) and searches for every “H2” paragraph (they will become destinations). Under the picture it creates a list of the found paragraphs separated by piles — this is x-refs sources.

The big text frame on the first page of the template should be labeled as “main” — this way the script knows where to perform the search.

An InDesign document — before running the script

After running the script

Click here to download.