I am exporting certain pages from InDesign CS5 to PDF. Outside of InDesign I need to gain access to the streams of text and replace them with different text (i.e. the PDF becomes a template and using PDFBox to change text values for the final printable document). I have run into a scenario that has me stumped…
I have a preformatted PDFPreset.joboptions file and a transparency flattener file that are called from applescript. It successfully exports a PDF. When I use the File->Adobe PDF Preset or File->Export… they produce a file that looks the same but is constructed differently than the export function in applescript. The difference being the availability of streams of text in the PDF.
Has anybody seen this problem before - using the same presets and getting different results from applescript vs GUI? I have included my export code that generates a PDF without accessible text. (Note I haven’t included the preset or transparency flattener but the basic settings are X1a:2003, PDF1.3).
set PDFPreset to "myPDFPreset" as string
set myExportFile to "File1.pdf" as string
tell application "Adobe InDesign CS5"
set myPDFExportPreset to PDF export preset PDFPreset
set page range of PDF export preferences to page 1
tell active document to set blending space of transparency preferences to CMYK
tell active document
export format PDF type to myExportFile using myPDFExportPreset without showing options
Reopening this thread as I have a similar issue. We’re using a script to export a PDF and actually call the name of the PDF Export preset. When comparing the scripted export vs. a GUI export, we find differences in the gradient areas of our PDFs. Has anyone else seen this issue or other issues with the PDF comparison between scripted and GUI? If so, what has been your solution?