PDF version of this page

Maintenance

Lookup Table Maintenance is a separate function of FormTrap Spooler Version 8, with the Lookup Table used by both FTForm8 and by the production system. Lookup Table Maintenance should be a to a file accessible to FTForm8, in the same way as substitution files. Transfer of the file to Production is done the same way as Substitutions, in Spooler, Data Folders.

Lookup tables are an option when defining Delivery Tags and Form Fields. A lookup table element contains two fields; Name and Value. Name is the "lookup", normally type-of-lookup suffixed with a field from the FormTrap XML definition, which substitutes the Value portion of the table entry into the Delivery Tag or Form Field. Example: "Staff Email WPG" returns "Paul.Green@FormTrap.com". Any number of different lookup tables may be defined, all are stored in the one XML file.

Lookup Table in Detail

The Lookup table holds Name which is used to look up Value. This is a section of a lookup table:

Lookup name is sorted. Multiple entry types may be included in the one table - in this one we have a range of PayFrequency-x names used to lookup the literal values for use on a form. We also have other entry types that expand on the initials of a staff person to provide their email address (Staff Email iii) and the closest printer to their desks (Staff Printer iii). The last case is flexible, moving a staff member requires a one-time change to their Staff Printer Value to have the FormTrap System redirect their output.

Name is typically a description, followed by the code. Code should be defined as "Trim" to remove spaces. The looked-up Value is what gets returned from lookup table substitution. The example shows PayFrequency-x lookup Name used to substitute the literal Value into a form.

Lookup tables are held as a single XML file called lookup.xml. Lookup table may be common to all Data Folders your FormTrap system or private to a single Data Folder.

On the form, we'd like to show the value from the lookup table in place of the code. First define the Lookup Entries for Pay Frequency as shown above. Save the completed Lookup Table in a new folder, such as the below:

        ..\fthome\v7\substitutions-work         or         ..\fthome\v8\substitutions-work

Top

Update the Correct Substitutions Folder in the FormTrap Spooler

To make the amended Lookup Table available to FormTrap Spooler, go to Data folders, locate the data folder where you want to apply the lookup table and press Folder properties....

Look at window and see if the folder has Use private substitution folders for this data folder ticked, then Cancel.

If ticked, select the Substitutions folder within the Data Folder...

... otherwise select the common substitutions folder as shown ...

Press Add substitution files ... and select lookup.xml for transfer into the Spooler.

Top

Define Formula in (data)

Define a Formula for substitution. Select type as Concatenated/substituted field (text).

Define the formula as shown:

Name is the name of this formula, you will use this as the link in the text field on the form.

The concatenated field is a constant (PayFrequency-) with the Insert... of the Payment Frequency code afterwards.

Substitution select Substitute from lookup table from the pull-down.

Test bench allows you to see what the resulting lookup name will be.

Note that you can use more than one code in a lookup table name, this as an example allows customer code and department to supply email address:

Top

Define data source in (form)

Define a text field to print the substitution. Select Link as the formula field.

Top