HomeStartingEnvironmentDBMSVisualPQLProceduresSQLFormsHost/APIIndex
Forms homecontents start chapter top of pagebottom of pagenext page index General Clauses

General Clauses

Various clauses and specifications are common to several commands. The command specifications include a set of clauses labeled General Clauses. This documents these general clauses. The
video options apply to a number of clauses.

The general clauses are:

ACTIVITIES
AT
AUTOTAB
BOTTOM
CLEAR
DATA
ERROR
LABELS
PAD
PAGESIZE
PROMPT

homecontents start chapter top of pagebottom of pagenext page index

ACTIVITIES

ACTIVITIES permissions
Specifies permissions for the commands and actions that are allowed. If the ACTIVITIES clause is omitted, all activities except AUTOCASEDELETE are allowed. Activities can be specified on the FORM, RECORD or TABLE commands and the USER clause. Field level activities (MODIFY or NOMODIFY), can be specified at the Page, Group and Field levels.

Permissions on the FORM level are the defaults for all screens in the form. Permissions allowed at the FORM level can be disallowed for individual screens; disallowed permissions cannot be reinstated at lower levels. ACTIVITIES restricted for a USER GROUP at a given level cannot be allowed at a lower level.

To disallow any permission, prefix the permission keyword with "NO", for example, NOREAD. The following permissions can be specified:

READ
read cases and records
WRITE
write cases and records
MODIFY
modify fields in existing records
FIND
use FIND mode
SEARCH
use SEARCH mode
DELETE
delete records
NEWCASES
create new cases
NEWRECORDS
create new records
NEWROWS
create new rows
OLDCASES
access existing cases
LOCKCHANGE
change LOCK status of screen
OLDRECORDS
access existing records
AUTOUPDATE
automatically update records without prompt
AUTOCASEDELETE
automatically delete cases when all records for that case are deleted
VERIFY
use VERIFY mode
CHANGE
change data in VERIFY mode
ALL
all activities are allowed
NONE
no activities are allowed

homecontents start chapter top of pagebottom of pagenext page index

AT

AT [ row ] [, column ]
AT specifies the starting position for the display element with which it is used. When used as a clause on the GROUP command, it specifies the starting position of the first display element within the group.

Row and column specify screen coordinate numbers. The top row on the screen is row 1 (one). The leftmost position on the screen is column 1 (one). The maximum values for row is 30 and for column is 80. Forms uses the bottom two or three rows for the status and command areas. The BOTTOM clause is used to set the number of rows used for the bottom area. AT may not position elements in the bottom area.

Row and column positions can be specified in either absolute or relative terms. Relative positions are relative to the current default position. The default position is one row greater and in the same column as the starting position of the previous displayed element. The initial position for the first screen element is at (1,1). Relative positioning is specified by prefixing the row or column with a plus or minus sign. AT -10,+40 specifies a placement ten rows higher and forty columns to the right of the current default position.

The stand-alone AT command resets the current default location.

An asterisk ( * ) may be used instead of row or column numbers to indicate the maximum row or column. For example:

AT 1 , 1
positions to the upper left corner.
AT * , 1
positions at the last row, column 1.
AT , 12
positions at column 12 of the current line.
AT -1 , 1
positions at the beginning of the previous line.
AT , +10
positions 10 columns from the beginning of the previous field.

homecontents start chapter top of pagebottom of pagenext page index

AUTOTAB

AUTOTAB specifies that, when the cursor moves past the last character of a field, it automatically goes to the next field. With NOAUTOTAB (the default), the user must explicitly move away from the field. Similarly, with AUTOTAB specified, if the user moves back past the first character of a field, the cursor goes to the previous field.

homecontents start chapter top of pagebottom of pagenext page index

BOTTOM

BOTTOM {2 | 3}
Specifies that either 2 or 3 lines are used for the status area at the bottom of the screen. 3 is the default.

homecontents start chapter top of pagebottom of pagenext page index

CLEAR

CLEAR 'character'
Specifies the character used to delineate a data field which is not yet filled in. A period ( . ) is the default.

Example: To delineate data fields with an underscore, specify:
CLEAR '_'

homecontents start chapter top of pagebottom of pagenext page index

DATA

DATA { HILITE | VIDEO } video_options
Specifies the
video treatment for the data area of fields.

HILITE

VIDEO

homecontents start chapter top of pagebottom of pagenext page index

ERROR

ERROR message_number [VIDEO video_options] 'error_text' [message_number [VIDEO video_options] 'error_text' ... ]
Specifies alternate text for messages. Each message consists of the message_number followed by text. See
messages for a full list of default messages.

Error messages apply to the level (FORM, SCREEN, PAGE, GROUP, FIELD) at which they are defined and to all inner levels unless overridden by another error message defined at the inner level. Video_options can be specified for error messages. The default VIDEO option is BELL. The NOBELL option turns off the 'bell' or 'beep' when an error message is displayed.

Example: To change the messages for errors 15 and 47 to
"This field must be two digits." and "Jobcode must be between 10 and 60.", and have the messages displayed in inverse and have a bell sound, specify:

FIELD JOBCODE -
ERROR 15 VIDEO BELL INVERSE -
'This field must be two digits.'-
47 VIDEO BELL INVERSE -
'Jobcode must be between 10 and 60.'

homecontents start chapter top of pagebottom of pagenext page index

LABELS

LABELS n
Specifies that value labels, "n" characters long, are displayed next to all fields for which value labels are defined. If the LABELS clause is omitted, value labels are not displayed.

Example: To display 20 characters of value labels next to all data fields, specify:

FORM TESTFORM -
       LABELS 20

homecontents start chapter top of pagebottom of pagenext page index

PAD

PAD [ n ] [, m ]
Specifies the display width of prompt (n) and data (m). By default, the display width of prompts are half the screen width and the display width of data is the width of the field plus 1.

Explicit prompts (specified on a PROMPT clause) are not truncated, even if the width of the explicit prompt exceeds the value specified for n. Similarly, data areas are not truncated, even if the width of the data item exceeds m. (Use the WIDTH clause on the FIELD command to alter the data width of a field.)

Prompts and character data are left justified and padded with blanks. Numeric data is right justified with leading zeros removed.

Example: Value labels are displayed one column to the right of a field's data area. If there are several such fields of varying width, and you want to align the value labels, specify a width for the data items which is the maximum for any data item. To reserve 15 columns for all data areas and align the value labels, specify:

PAD  , 15

homecontents start chapter top of pagebottom of pagenext page index

PAGESIZE

PAGESIZE [ r ] [, c ]
Specifies the size of the display area (r = number of rows, c = number of columns). If you specify sizes smaller than the execution window (30,80), the display takes up the top left portion of the window. If you specify a display area larger than the execution window, you will not be able to see your display and the screen formatting may produce undesirable results.

Do not use this clause with the execution window under Windows or Motif.

The specified row size does not include the bottom display area as defined by the BOTTOM clause.

The default useable size is 27 by 80 (window size less the status area).

homecontents start chapter top of pagebottom of pagenext page index

PROMPT

PROMPT { HILITE | VIDEO } video_options
Specifies the video treatment of the prompt area of a field. (See
video treatment for a description of video_options.)

HILITE

VIDEO

homecontents start chapter top of pagebottom of pagenext page index

video_options

Video options are specified by the keywords AT0 through AT16 or by synonyms.

AT1 through AT6 are essentially 'monochrome' options which use a default foreground of black with a default background of white.

AT8 through AT16 are colour options which control both foreground and background and, if any of these are specified, they turn the monochrome defaults off so that, if a foreground colour is not specified, it is black; if a background colour is not specified, it is white.

The colour foreground is dim by default. The colour background is bold by default. Multiple options can be specified together. When using colours, specify blue, green red and bold to get white.

AT0 No effect
AT1 BOLD - Blue on default background
AT2 INVERSE - Swaps foreground and background (only if colours not specified)
AT3 No effect
AT4 UNDERLINE - Underlines with a black line (works with colours)
AT5 DIM - Dim foreground Grey on default background
AT6 GREY - Dim background default foreground on Grey
AT7 No effect
AT8 FGBLUE - Foreground Blue
AT9 FGGREEN- Foreground Green
AT10 FGRED - Foreground Ref
AT11 FGBOLD - Foreground Colour Bold
AT12 BGBLUE - Background Blue
AT13 BGGREEN - Background Green
AT14 BGRED - Background Red
AT15 No effect
AT16 BGDIM - Background colour dim

Examples: To highlight the data field where the cursor is positioned, in bold inverse, specify either of the following:

DATA HILITE INVERSE BOLD
DATA HILITE AT2 AT1

To display all data fields in inverse, specify either of the following:

DATA VIDEO INVERSE
DATA VIDEO AT2

To display all fields in inverse and to make them bold when being prompted, specify either of the following:

DATA HILITE BOLD VIDEO INVERSE
DATA HILITE AT1 VIDEO AT2

homecontents start chapter top of pagebottom of pagenext page index