|
Visual Builder Special Variables
Visual Builder has a number of special variables
that can be set to alter the operation of forms.
CopiesToPrint =
<nn>
The number of copies to print of the form. This
should be specified in the form's Questions|Preface or Postscript
sections. Assigning a numeric value to this variable will override
the default "number of copies to print" property of the form.
HoldRecord =
TRUE | FALSE
This variable should be assigned a TRUE or FALSE
value in the rules section of the form. If TRUE is assigned to the
variable the current record is "held over" for printing again on
the next line. This can be useful if you need to display a certain
record repeatedly until some other process is complete.
GroupChange
This variable is not normally assigned a value
but it can be inspected to see if a group (such as a total,
sub-total or heading) has changed. Some action can then be
performed based on this change.
SortOrder =
<n> | Expression
The sort order of a form can be dynamically
altered by declaring this variable and assigning it a value. If the
assigned value is numeric, then sorting is determined by the
matching entry in the sort order list. For example, if the third
sort sequence is "account", then assigning 3 to the variable
SortOrder will result in sorting by account. If a character string
is assigned to this variable then the form will be sorted by that
string. For example:
SortOrder := 'Account
+ Name'
will sort the form by account code plus account
name. Visual Builder only checks for the existence of the
SortOrder variable if a
sort order sequence has not already been defined for the form. So
if you want the system to use the contents of this variable it is
important that you leave the Sort field
in the Link tab blank. Visual Builder
attempts to apply the sort sequence specified by SortOrder to all bodies not assigned a
Sort field value.
JoinParentKey =
Expression
If specified this is used as the join key
expression for all bodies on a form. The scope of all body forms is
limited to matching this expression. For example:
JoinParentKey :=
'Invoice->Invoiceno'
If the JoinParentkey variable is not defined, Visual
Builder assumes that the join relationship between the parent and
any joined bodies is determined by the current Sort expression of the parent form. For example, if
an invoice form is sorted by invoice number, then any bodies joined
to the invoice must match the invoice number of the parent. It is
sometimes convenient to sort by something other than the invoice
number, such as the invoice date. In this case it is necessary to
define the JoinParentKey variable
to ensure that the contents of the invoice form is still limited to
matching the invoice number. The JoinParentKey variable is usually defined in
the Preface section of the form found
on the Questions tab.
|