DLGBOX |
"Dlgbox" is used to declare a box based on a main screen, with optional declaration of folders, left-hand lists and buttons.
[Local
]Dlgbox
Mask masque
Buttonlist_buttonW
ith list_shortcut Codedlist_status
[ Titledtitle_box ]
[ Atposition ]
[ list_folder ]
[ liste_bgauche ]
Asabrev
|
Element |
Description |
Restrictions |
|
mask |
Identification of the main mask in
one of the following forms |
classe0 indicates a
mask. |
|
expr_c |
Alphanumeric expression whose result is a mask name in the form of an identifier or an absolute or relative path. |
|
|
list_button |
List of alphanumeric expressions, giving the text of each button separated by the character ','. |
|
|
list_shortcut |
List of one-character expressions separated by the character ','. |
the character must be part of the text of the button |
|
list_status |
List of integer expressions separated by the character ','. |
For standard buttons, use global variables |
|
title_box |
Alphanumeric expression for the title of the box |
|
|
position |
Position of pick box on
screen in the form: |
This position must be within the screen. |
|
exp_lig |
Numerical expression of the
number of the line on screen, from which the pick box will be displayed |
|
|
exp_col |
Numerical expression of the
number of the column on screen, from which the pick box will be displayed |
|
|
list_folder |
List of folders separated by the
character ','. |
Max 8 folders |
|
masque1 |
Identifier of a folder in one of
the following forms: |
classe1 indicates a
mask. |
|
titre_onglet |
Alphanumeric expression for the title of the folder |
|
|
liste_bgauche |
list of left hand window separated
by the character ','. |
16 maximum |
|
typ_boîte |
Listbox
: for a simple list |
|
|
classe2 |
abbreviation indicating the table on which the left hand list is based |
|
|
bgauche |
Identifier for the left hand list
in the form: |
|
|
liste_champ |
List of fields in the left hand box
separated by the character ','. |
the total size of the fields shall be less than 240 octets. |
|
field |
Identifier of a field in one of the
following forms: |
|
|
titre_champ |
Alphanumeric expression of the field title |
|
|
titre_bgauche |
Alphanumeric expression for the title of the left hand list |
|
|
abrev |
abbreviation indicating the box |
|
# display of a window with 4 buttons at the bottom:
# definition of input box
# with mask opened
Local DlgboxMask
ZMOTSA00 [ZM00]
& Button "Button A", "Button B",
"Button C", "END"
& With
"A","B","C","F"
& Coded 1901,1902,1903,1904
& Titled "Box title"
& As [BOI1]
# opening of mask
Local Mask ZMOTSA00 [ZM00]
# definition of input box
# with use of mask abbreviation
Local DlgboxMask [ZM00]
& Button "Button A", " Button B",
" Button C", "END"
& With
"A","B","C","F"
& Coded 1901,1902,1903,1904
& Titled "Box title"
& As [BOI1]
# opening of mask
Local Mask ZMOTSA00 [ZM00]
Local Char WMASK
WMASK ="ZMOTSA00"
# definition of input box
Local DlgboxMask = WMASK
& Button " Button A", " Button B",
" Button C", "END"
& With
"A","B","C","F"
& Coded 1901,1902,1903,1904
& Titled "Box title"
& As [BOI1]
# display of a window with OK button and 6 folders:
# opening of header mask and
of 6 folders
Local Mask ZMOTSA00 [ZM00]
Local Mask ZMOTSA01 [ZM01]
Local Mask ZMOTSA02 [ZM02]
Local Mask ZMOTSA03 [ZM03]
Local Mask ZMOTSA04 [ZM04]
Local Mask ZMOTSA05 [ZM05]
Local Mask ZMOTSA06 [ZM06]
# definition of input box
# with use of mask abbreviation
Local DlgboxMask [ZM00]
& Button "END" With "E" Coded 1901
& Titled "Box title"
& Folder Mask [ZM01] Titled "Folder 1"
& Folder Mask [ZM02] Titled " Folder 2"
& Folder Mask [ZM03] Titled " Folder 3"
& Folder Mask [ZM04] Titled " Folder 4"
& Folder Mask [ZM05] Titled " Folder 5"
& Folder Mask [ZM06] Titled " Folder 6"
& As [BOI1]
# display of a window with OK button, 2 tree-structure lists, 1 simple list:
# opening of table on which
the left hand lists are based
Local File ZMOTTBX [ZMT]
# opening of mask
Local Mask ZMOTSA00 [ZM00]
# definition of input box
# with use of mask abbreviation
Local DlgboxMask [ZM00]
& Button "END" With "E" Coded 1901
& Titled "Box title"
& Treebox [ZMT] GAUCHE1
& Treebox [ZMT] GAUCHE1
& [F:ZMT]YITMREF Titled
"",
& [F:ZMT]YUOM Titled
"",
& [F:ZMT]YITMDES Titled
""
& Titled "Main"
& Treebox [ZMT] GAUCHE2
& "Article
"+[F:ZMT]YITMREF Titled "",
& "Unit in
"+num$([F:ZMT]YUOM) Titled "",
& "Rate in
"+num$([F:ZMT]YVATRAT)+" %" Titled ""
& Titled "Detailed"
& Listbox [ZMT] GAUCHE3
& [F:ZMT]YITMREF Titled
"Article",
& [F:ZMT]YUOM Titled "Unit",
& [F:ZMT]YVATRAT Titled
"Rate",
& [F:ZMT]YBASPRI Titled
"Price"
& Titled "Standard
list"
& As [BOI1]
# entry in a window :
# variable recovering selected
button
Local Integer RESU
# definition of input box
# with mask opened
Local DlgboxMask
ZMOTSA00 [ZM00]
& Button "END"
& With "E"
& Coded 1901
& Titled "Box title"
& As [BOI1]
$MENU
# display of window
Boxact [BOI1]
# entry in window :
Boxinp [BOI1] using RESU
# action according to button
activated
Case RESU
when 1901 Goto FIN
when Default Goto FIN
Endcase
Goto MENU
# closing box and mask
Close Local Dlgbox[BOI1]
Close Local Mask [ZM00]
"Dlgbox" is used to declare a box that may not be full page. It is based on a main screen. This box is identified by an abbreviation that will be used to display the box, enter or delete from it on screen or remove it from memory using the instructions Boxact, Dlgbox, Boxclr et Close Dlgbox.
It is a stand-alone window in Windows.
A single mask, or a main mask and folders (max 8) may be
displayed in this window.
In defining a folder, the keyword Folder is used.
Left hand lists may be defined (max 16).
In defining a simple left hand list, the keyword Listbox is
used. In defining a tree-structure left hand list, the keyword Treebox
is used.
Both simple and tree-structured left-hand lists may be defined for one box.
In a Listbox, the primary key fields must be declared at least.
In a Treebox, there is no restriction on field definition. Field titles are not
used in a Treebox.
The Currbox variable is supplied with the name of the current left hand list.
Buttons may be defined for this box.
For definition of all buttons, the keyword Button will be used
once.
For each button, a text, a shortcut and a status must be entered, that will be
tested in the input instruction Boxinp via a variable.
The statuses used by the supervisor are stored in global
variables. It is normally these global variables that will be entered in the
key word Coded.
Example:
|
Global
|
Status |
Usage |
|
GSTAOK |
1029 |
used for an "OK" button |
|
GSTAFIN |
1792 |
used for an "END" button |
|
GSTACRE |
93 |
used for a "CREATION" button |
Status ranges to be observed:
|
Status |
Usage |
|
1120 .. 1199 |
statuses reserved for standard
|
|
1220 .. 1239 |
statuses reserved for specific
|
|
1901 .. 1999 |
statuses reserved for standard
|
|
2220 .. 2229 |
statuses reserved for specific
|
No more than 25 screen OBJects may be opened at any one time. Screen-OBJects are boxes opened by Mesbox, Inpbox, Dlgbox, Listbox, Treebox, Pickbox (including left hand lists). This number must also include the "working window" opening when an application is started.
Declaring a screen-OBJect with an abbreviation already in use by another screen-OBJect closes the latter.
The instruction Close [Local]Dlgbox deletes from memory boxed opened by [Local] Dlgbox. If the abbreviation is not specified, all locally opened windows are deleted.
When a sub-programme ends, boxes opened by Local Dlgbox in this sub-programme are closed as if by CLose Dlgbox.
|
Error |
Description |
|
ERCLAS(7) |
Class is not an abbreviation |
|
ERMABR(37) |
2 masks with the same abbreviation |
|
ERMODE(10) |
a title is not alphanumeric |
Inpbox - Mesbox - Boxact - Fillbox - Boxinp - Boxclr - Currbox - Status
|
|