To work with the constants in the environment, select the Constant dictionary option in the 4GL Editor's Repository menu.
The dialog box will automatically be opened at the DIC tab.
Notes:
- This option will only appear in the menu if the source in the active window is a VADELIA, SADELIA, WADELIA type program, or a VISUAL or WEB type management rule. Where this is not the case, this option will not appear in the menu and if you click on the DIC tab, the dialog box will appear completely shaded.
- You can minimize the dialog box by double-clicking on the title bar, which will leave only the title bar visible.
Data entry
Name
Character string used as a filter to limit the number of constants displayed.
Examples:
_TRI* |
Displays only those constants whose names begin with "_TRI". |
*TSD* |
Displays only those constants whose names contain the string "TSD". |
_TRI_TSD_AL |
Displays only the constant with this name. |
Lists
Constants
List of the constants respecting the name criterion. For each constant, the name and the value are displayed.
Context-sensitive menus
"Name" field
Contains the list of default filters and the four most recent filters set.
Default filter settings:
[ ] |
No constants. |
* |
All constants. |
Constant list
Retrieve
When only one constant has been selected, this option is used to insert its name into the source in the active document, at the cursor's current position.
This option is only active if one or more constants are selected from the list.
Default option.
Opens a dialog box that lets you copy a constant in the dictionary.
This dialog box is identical to the constant definition box.
This option is only active if one or more constants are selected in the list.
Opens a dialog box that lets you add a new constant.
Opens a dialog box that lets you modify the selected constants.
This option is only active if one or more constants are selected from the list.
Delete
Deletes the selected constants, after requesting confirmation.
This option is only active if one or more constants are selected from the list.
Individual comparison
Opens the Individual comparison dialog box for each of the selected constants.
This dialog box lets you start the comparison of the selected constant's definition with the definition of another constant (belonging to the same or to a different environment).
Global comparison
Opens the Global comparison dialog box allowing to start the comparison of object list between the current and another environment.
The list of objects to be compared is initialized with the selected constants.
Opens a dialog box enabling the selected constants to be held by the default correction.
This option is only visible in correction environments. It is only active if one or more constants are selected in the list and the user has a default correction.
Opens a dialog box displaying information on the selected constant, such as the owner-software engineer's name and the dates and times it was created and last modified.
Note:
When a dictionary constant is used in a Visual program, it is considered without its blanks at the end, in the same way as the literal constants manipulated directly in the 4GL source. However, the intrinsic length of this dictionary constant is the length including the final blanks.
The purpose of the blanks added to the end of a dictionary constant is to facilitate translation management in the event of multilingual generation. Since the translations of a dictionary constant cannot be longer than the original text, adding blanks at the end allows the translations to be longer.
Example:
_MY_CST_1 dictionary constant 'abcd '
IF _MY_CST_1 = 'abcd'
/* Test returning true because _MY_CST_1 is worth 'abcd'
END
ALPHA(20) MyAlpha20
MyAlpha20 = _MY_CST_1 // 'END'
MyAlpha20 will be worth 'abcd END' because _MY_CST_1 has a length of 9 (and not 4.)