You are here: Section Rules Reference > Section Rules Summary > AddMultiPageTIFF > Using the Type Option

Using the Type Option

Use the Type option to tell the AddMultiPageTIFF rule that the target image is a PDF file which contains TIFF, JPEG, or bitmap images. The first image found in the PDF file is inserted on the triggering form or image. Subsequent images in the PDF file trigger additional pages which are appended in the order in which they appear in the PDF file.

     
Note If the PDF file contains anything else, such as text, those items will be discarded. Only TIFF, JPEG, and bitmap images are added.

Keep in mind...

AddMultiPageTIFF DAL(PDF_DAL.dal),Only(ODD),TYPE(P)

AddMultiPageTIFF DAL(PDF_DAL.dal),Only(ODD),TYPE(P)

Assume the first PDF file contains four TIFF images. The second PDF file contains five TIFF images.

After executing the two rules, there will be five pages in the form. The first four pages will have two TIFF images each (one from the first rule and one from the second) and the final page will contain the last TIFF image from the 5-image PDF file.

Be aware that the placement of the images on the page can make them overlap.

     
Note This rule supports long file names on 32-bit Windows operating systems.

Using the File option with the Type option

This example imports the T_FILE.PDF file from the PDF_File directory. Using this file, the GenData program adds the images in the PDF file to the form set. Each image in the PDF file causes a duplicate of the original FAP file to be appended to the form. This duplicate contains the image from the PDF file. If the T_FILE.PDF file does not exist, no error messages appear because the OPT option is set to Yes.

Using the DAL option with the Type option

This example executes the PDF_NAME.DAL DAL script which returns the file name, F_DAL.PDF. Using this file name, the GenData program adds the images contained in the PDF file to the form set. Each image in the PDF file causes a duplicate of the original FAP file to be appended to the form. This duplicate contains the image from the PDF file. Only the odd-numbered images in the PDF file are included because the Only option is set to Odd.

Using the SCH option with the Type option

This example imports PDF files (F_SCH1.PDF, F_SCH2.PDF, and F_SCH3.PDF) based on the content of lines in the file designated by the ExtrFile option in the Data control group. Using this file, the GenData program adds the images contained in the three PDF files to the form set. Each image in each PDF file causes a duplicate of the original FAP file to be appended to the form. This duplicate contains the image from the PDF file. The images from the PDF files are embedded in the NA file because the Embed option is set to Yes.

Here is an example of the extract file records pointed to by the ExtrFile option:

0 1

1 1

SCOxxxxxxxHEADERREC

PDF_File_Name .\PDF\F_SCH1.PDF

     
Note This option lets you import and process multiple PDF files because of the way the file name and path are specified—one file per entry in the file pointed to by the ExtrFile option.

Using the GVM option with the Type option

This example imports a PDF file based on file name contained in the GVM variable called PDF_File_GVM. Using the PDF file name and path in the GVM variable, the GenData program adds the images contained in the PDF file to the form set. Each image in the PDF file causes a duplicate of the original FAP file to be appended to the form. This duplicate contains the image from the PDF file.

     
Note Keep in mind you can use any valid GVM variable, no matter how it is created or assigned.

To create the PDF_File_GVM variable, you would include the following INI option in your FSISYS.INI and add its definition in the TRNDFDFL.DFD file.

< GenTrnDummyFields >

PDF_File_GVM = .\PDF_gvm\T_GVM

See also