Data Merge PDF Export vs regular PDF Export
December 17, 2016 1 Comment
From time to time, I receive feedback on my Data Merge to Single Records script saying that – when exporting to PDF – spreads or hyperlinks won’t work. There is a reason for this and it has nothing to do with the script, but a behaviour (or bug) of how Data Merge exports to PDF.
A regular user of Adobe InDesign will be aware that there are two different kinds of PDF export – print and interactive. What users may not be aware of is that there is a third, more subtle method of PDF export, and that is PDF export during Data Merge.
On the surface, the PDF export looks the same, but the devil is in the detail. When merging directly to a PDF directly from the Data Merge palette (or using the Data Merge to Single Record script), there are options that cannot be chosen. These are:
- The ability to merge to an interactive PDF
- The page range (not the record range)
- Create Tagged PDF
- Create Acrobat Layers
With the exception of being unable to check the spreads checkbox, the other limitations don’t usually pose too many issues when creating print-ready PDFs. I don’t know the reasons why these options are unable to be checked and in my mind it doesn’t make any sense that they should not be able to be selected at all.
But I digress… if interactive PDFs need to be created using Data Merge (for example, a survey where the participant was directly named during the Data Merge) then this cannot be done via the export to PDF directly from Data Merge.
There is a workaround
The solution is to merge to an InDesign file, and then export the merged InDesign file to an interactive PDF.
This situation presented itself in a real-world example where a school wanted to provide an interactive form to the parents of the students. The form would contain the student’s name, class number and teacher from the Data Merge panel, but other components of the document were interactive form fields. The PDFs had the name of the student and the teacher as the filename. The solution was as follows:
- Use the Data Merge to Single Record script to merge to InDesign files to a new location using the name of the student and the teacher in the filename.
- Once created into a new directory, select a single file at random from that directory and ensure that it opens correctly without any font substitution. Export this single file to an interactive PDF using the settings you would like to use for the remaining files, and click OK.
- Open the interactive PDF that was created to make sure it opens as intended. If so, close the PDF and delete it (the reason will become apparent in a moment).
- Close all documents and run the Batch Convert script from Peter Kahrel. If you can’t get to the script palette from here because regular palettes are hidden and replaced with a dialog showing recent documents, go to the Window Menu, Utilities, then Scripts.
- Once Peter’s script is open, choose the input folder by pointing to the folder containing the newly created InDesign files. The three checkboxes underneath this option should be unchecked.
- Choose an output folder by pointing to a destination folder for the interactive PDFs.
- Choose the source format as InDesign and the target format as PDF (interactive).
- Click OK
Peter’s script will now begin to work through the files exporting them to interactive PDFs. While this technique works, it’s annoying to have to double-handle files. One other frustration with this method is that the interactive export settings have to be initially created from a “sacrificial” PDF. To be fair, this has nothing to do with Peter’s script, but rather a “feature” (or lack of…) by InDesign. Unlike the print PDF presets, there is no ability to create interactive PDF presets.
This is a feature I would like to see and if you feel the same way, make sure to tell the Adobe InDesign team at their feature request/bug report form. In fact, I personally wouldn’t stop there… instead of having to go through this entire procedure, I’d let them know that Data Merge’s features need to be expanded and improved upon so that workarounds like this should not be necessary.