The following document will go through the functionality found within JetTrac PDFPageExtract. This module is used to programmatically extracts pages from a PDF form and saves them as a separate PDF. The set up for this module is identical to that of JetTrac PDFPageDelete.
Please note that any files edited while setting up JetTrac PDFPageExtract should be edited using Notepad or Notepad++. Do not use Microsoft Word or Wordpad as these text editors will add formatting that will interfere with the program reading the files.
If you need assistance in installing and configuring JetTrac PDFPageExtract™, call Pro Technology Automation, Inc. at 805-527-1248 or email us at firstname.lastname@example.org. Please note that the JetTrac PDFPageExtract™ license fee does not cover configuration services and technical support so there may be an additional charge. Please ensure you read these instructions carefully before calling for technical support.
To run the program, you will need to have the following files located in the same folder:
Executable files and dll files should not be edited for any reason.
In addition, JetTrac PDFPageExtract requires an input configuration .ini file and an input XML file. These will be edited to set up the functionality for the module.
JetTrac PDFPageExtract takes an input PDF, extracts pages that you specify, then outputs a new PDF containing only the pages that were extracted.
When setting up a job step using JTPDFPageExtract in JobConfig the only lines of the config you need to worry about are the first and the last two, the Config file, the Input PDF and the Output PDF. If left as an asterisk * the input will be whatever file is in the data folder that triggered the job running. This works well if it’s the first step but if the input is also the output of a previous job step you would need to specify the fully qualified path of the input pdf you want to extract specific pages from. All other fields should be filled with the fully qualified path to the intended file. Eg: C:\JetTrac\…\input.pdf
In JobConfig, file paths entered should not be in quotes.
As with all modules, there is a dropdown to select whether or not the job should stop completely if this step fails. If you select Yes, any error will terminate the job process and write to the log file what happened, if no, then the job will try to continue anyways. However if any steps further down the line rely on the output of a job set to not stop on error, they may not work properly.
For more specifics go to the JetTrac Field ServiceJobConfig page.
The command line for JetTrac Email is as follows:
“C:\JTPDFPageExtract.exe” “C:\Input.xml” “C:\Input.pdf” “C:\Output.pdf” “C:\Config.ini” “C:\JTPDFPageExtract.log”
In this we are referencing the .exe for the module, the input XML data, the input PDF that we wish to extract pages from, the file path where you wish to save the new output PDF, the configuration file used to set up the module’s specific functionality, and the log file.
The following is a sample configuration .ini file used when running JetTrac PDFPageExtract:
This configuration .ini file contains two key values. The first key value specifies the name of the field found in the XML that has the list of pages, or page ranges that the module will use to extract the appropriate pages. The second line can either be set to “y” or “n” and tells the module if you wish to remove pages with no data from the extracted form package. A “y” will cause the module to remove any pages that are included in the page numbers or range of page numbers that do not contain any data. A “n” will include all extracted pages, even if they are blank, in the output PDF.
The input XML file must contain the field that contains a comma separated list of pages you wish to extract from the PDF. This comma separated list can contain, in numerical order, any combination of page ranges and/or individual pages. The following is an example value for this field: 6-26,28-29,31. In this example, the PDF will have 24 pages in total extracted. Please also note that the page numbers are comma separated with NO spaces.