This example imports the T_FILE.TIF file from the TIF_File directory. Using this file, the GenData program adds the TIFF images contained in the single TIFF file to the form set. Each image in the TIFF file causes a duplicate of the original FAP file to be appended to the form. This duplicate contains the bitmap image.
Keep in mind that if the OPT option is set to No, which is the default, the system expects you to provide a file name, otherwise you get an error.
If you set the OPT option to Yes, this tells the system that if the data for the file name is not provided it should skip to the next rule without creating an error message. Setting OPT to Yes simply tells the system that if no file name is provided, regardless of the mapping method you are using, it should not be considered an error. Here is an example:
AddMultiPageTiff OPT(Y), SRCH(1,TIFF 10,25)
You get no error if the TIFF record does not exist in the extract file or if there is TIFF record but as offset 10 for 25 bytes, there is nothing but spaces. If the OPT(Y) option is omitted, you get one of these messages, depending on your situation:
SRCH() A record matching the search mask <1,TIFF> could not be
located.
SRCH() Filename location within search record <1,TIFF> is blank.
Offset <10,> Length <25>.
Here is another example:
AddMultiPageTiff OPT(Y), GVM(TIFF_GVM)
If TIFF_GVM contains no data and the OPT(Y) option is specified, you get no error. If the OPT(Y) option is omitted, the system generates an error similar to this one:
GVM(<TIFF_GVM>) Global variable does not exist or is empty.
Here is another example:
AddMultiPageTiff OPT(Y), DAL(AddTiff.dal)
If processing the AddTiff.dal script results in an empty string and the OPT(Y) option is specified, you get no error. If the OPT(Y) option is omitted, the system generates an error similar to this one:
DAL(<AddTiff.dal>) script returned no result or result was blank.
Note | Remember that if no data exists and the OPT option is set to Yes, no error message appears. |
© Copyright 2012, Oracle and/or its affiliates. All rights reserved. Legal notices.