This tab only applies to domains with data type Enumerated or Set.
Use this tab to define the constants that belong to a domain of data
type Enumerate, or Set, with language-dependent descriptions.
To define a constant:
- Specify the constant number
for internal usage.
- Specify the name of the
constant used in program scripts and defaults in form fields.
- Specify the language-dependent
description that a form field shows at runtime.
This tab contains a table with all the constants used in an Enumerated
or Set domain. The constants are displayed as records with the following
arguments:
-
Constant
-
Constant Name
-
Description
-
Label
In the
Enum or Set Values table, you
can add and remove constant records.
- To add a constant record to
a domain, click
Add and fill in the
required fields. Specify a code and a name. Alternatively, right-click in the
table and, on the shortcut menu, select
.
- To remove a constant record,
right-click the record and, on the shortcut menu, select
.
- Enum or Set Values
-
- Constant
- The constant number that represents the internal enumerated
field value. This number determines the sequence in which the enum descriptions
are displayed at runtime.
-
If a table index includes/consists of an enumerate field,
the constant determines the sequence of records according to the index.
You can also use the constant number for greater than and
less than expressions in scripts. For example, domain
tryesno
has value
yes
, with constant number 1, and value
no
, with constant number 2. For this domain,
the expression
tryesno.no > tryesno.yes
is true.
-
Allowed values:
Whole number in the range 1 -255.
-
Allowed values:
The highest present constant number raised by 1.
- Constant Name
- The constant name combined with the package code and domain
code. This is used to refer to an enumerated constant in scripts or expressions
on forms and reports.
-
Example:
Consider package code
ti
(Manufacturing), domain code
yesno
and constant name
yes
. To refer to this constant in a form
field with domain code
tiyesno
, use the expression
tiyesno.yes
.
-
Allowed values:
A text string that starts with an alphabetic character.
Spaces are only allowed at the end of the string.
- Description
- The content description of the label. This description is
used as a constant value of enumerated or set data types.
-
Allowed values:
This field is read-only for existing constant records,
because the description is a property of the
Label. You can
modify the description text in the label editor.
You can specify a constant description in the domain editor
when you add a new constant record. This description is an ASCII text with a
maximum label length of 70 characters.
- Label
- The label name for the
Description of the
enumerated or set constant.
-
When hovering above the label name, the domain editor shows
a hyperlink. Use this hyperlink to edit the label with the enumerate
description in the label editor.
-
Allowed values:
This field is read-only and is automatically generated when
you save the domain.
The generated label name is a concatenation of package code,
module code, domain code and constant number. For example:
ttadv.cmpt0001
-
Note: The label is generated when you save the
domain and can be modified in the label editor.
- Step Size
- A number used to automatically generate subsequent constant
values.
-
For example, if the first constant value is 10, and the step
size is 10, the second and third constant number are 20 and 30. This step size
enables you to insert in-between constant values later.
-
Allowed values:
10