VA FileMan V. 22.0 Programmer Manual Banner


 

Main Chapter Getting Started Manual Advanced User Manual

ScreenMan Forms


Relational Navigation: Forward Pointers

On a page of a form, you can place a block that contains fields from a file other than the Primary File of the form. If the file is reached via a forward pointer, you must define a Pointer Link for that block. The syntax of the Pointer Link property is similar to FileMan's relational syntax. When you define the Pointer link, your point of reference is the Primary File of the form.

In the following illustration, the Primary File of the form is the ORDER file (#16202). There are two blocks on the page. Block A contains fields from the ORDER file, and Block B contains fields from the CUSTOMER file (#16201). CUSTOMER NAME in the ORDER file points to the CUSTOMER file.

Example of a Form with Forward-Pointer Relational Navigation.

If CUSTOMER NAME is field #1, the Pointer Link property for Block B can be set to either "CUSTOMER NAME" or 1. The following sections describe in more detail the syntax for the Pointer Link property.

Syntax for Pointer Link -- Navigating Via DD Fields

In the valid formats listed below, "Pfield" is a pointer-type field. Both "Pfield" and "Field" can be either field names or field numbers. "Mult_field" is the name or number of a multiple field. "File" is the name or number of a file. A file or field name can be enclosed in quotation marks.

Format Explanation
Pfield The Primary File of the form has a field Pfield that points to the file associated with the block. That pointer field determines the record to display in the pointed-to block.
Pfield_1:Pfield_2: ... :Pfield_n The pointed-to block is reached after relational jumps across many files. Here, Pfield_1 in the Primary File points to File 2 that contains a Pfield_2 that points to File 3, etc. Finally, Pfield_n points to the file associated with the block being defined.
Field;Opt_spec The value of Field in the Primary File should be used to do a lookup into the file associated with the block.

You can control how the lookup is done by using any of the following optional specifiers (Opt_spec):

;I Use the Internal form of the field value for the lookup
;L Allow LAYGO
;IX(xref list) Use specific IndeX(es) in the lookup. (For example ;IX(B^C) specifies that the B and C index should be used.) If the specifier is not used, all indexes starting with the B index are used in the lookup.
Field;Opt_spec:File:Pfield_1: Pfield_2: ... :Pfield_n The pointed-to block is reached after relational jumps across many files. The first jump is accomplished with a lookup into File. See Opt_spec.
Mult_field_1:Mult_field_2: ... :Mult_field_n:Pfield The pointed-to block is reached after descending into subfiles of the Primary File and finally a relational jump via a pointer field within a subfile.
Syntax for Pointer Link -- Navigating Via Form-only Fields

Form-only fields can also be used to relationally link blocks.

In the formats below, the characters "FO" indicate that a form-only field is being identified. "Pform_only" is a pointer-type form-only field and "Form_only" is a form-only field that is not a pointer. Form_only and Pform_only are three-piece comma-delimited strings that uniquely identify form-only fields on the form. They have the following format:

Format of Form_only: Field_id,Block_id,Page_id

where

Valid formats are:

Format Explanation
FO(Pform_only) The pointer-type form-only field is a pointer to the file associated with the block being defined. The contents of the form-only field determines the record to display in the pointed-to file.
FO(Pform_only):Pfield_1: ... Pfield_n The pointed-to file is reached after relational jumps across many files. Here, the pointer-type form-only field points to File 1 that contains a Pfield_1 that points to File 2, etc. Finally, Pfield_n points to the file associated with the block being defined.
FO(Form_only);Opt_spec The value of the form-only field is used to do a lookup into the file associated with the block.

You can control how the lookup is done by using any of the following optional specifiers (Opt_spec):

;I Use the Internal form of the field value for the lookup
;L Allow LAYGO
;IX(xref list) Use specific IndeX(es) in the lookup. (For example ;IX(B^C) specifies that the B and C index should be used.) If this specifier is not used, all indexes starting with the B index are used in the lookup.
FO(Form_only);Opt_spec:File: Pfield_1: ... Pfield_n The pointed-to file is reached after relational jumps across many files. The first jump is accomplished with a lookup. See Opt_spec.

 


Reviewed/Updated: March 10, 2007