• Aucun résultat trouvé

Field Attributes

Dans le document Station 2624A (Page 49-52)

When defining an unprotected or transmit-only field, you must specify a field type (which has a set of implied at-tributes) and some explicit field attributes. Some of the attributes are checked as each data character is entered into the field, others are checked when the cursor is ready to leave the field, and still others are checked when the data in the form is to be transmitted to the host computer.

The implicit attributes are:

1. The set of characters which may be entered into the field.

2. The format restrictions, if any, for data items entered into the field.

3. Automatic editing, if any, that is performed when the ( cursor leaves the field.

Table 5-1 summarizes the implicit attributes associated with each field type.

The explicit attributes are:

1. Whether or not the terminal operator MUST enter a data item into the field (REGU I REDIOPTI ONAl).

2. Whether or not the data entry in the field is to be automatically justified when the cursor leaves the field

(JUSTIFY/NO JUSTIFY).

3. Whether or not every character position in the field must be filled by the terminal operator (TOTAL F I ll/NO TOTAL FIll).

Figure 5-5. Use of Shift-In and Shift-Out Codes

Table 5-1. Attributes by Field 'IYPe

Field Valid Input Field Format Automatic

Type Characters Restrictions Field Editing

ALL CHARACTERS ALL None None

ALPHABETIC Upper/lowercase None None

alphabetic, space

AUTO-UPSHIFT ALL (lowercase None None

alphabetic changed to uppercase when they are entered into the field)

ALPHANUMERIC Upper/lowercase None None

alphabetic, digits, space, period, minus sign, plus sign, comma

INTEGER Digits, space None None

SIGNED Digits, minus sign, No embedded spaces; None

DECIMAL plus sign, decimal only one decimal

point, space point; plus sign

(if present) must immediately precede most significant digit; minus sign (if present) must immediately precede most significant digit or immediately follow least significant digit

IMPLIED Digits, plus or No embedded spaces; Right justified;

DECIMAL minus sign, only one decimal if there is no

decimal point, point; plus sign explicit decimal

space (if present) must point, the implied

immediately precede decimal point is

most significant inserted at the

digit; minus sign proper position (if present) must

immediately precede most significant digit or immediately follow least significant digit;

completed entry must leave at least one space for decimal point to be added during field edit;

if explicit decimal poi nt is entered, the number of digits to the right of it must NOT exceed the number specified by the Implied Dec Digi h configuration field

CONSTANT None None None

5-5

Table 5-1. Attributes by Field 'JYpe (Continued)

Field Valid Input

Type Characters

INTEGER Digits, spaces

FILL

SIGNED Digits, minus sign,

DECIMAL plus sign, decin'l.sl

FILL point, space

REQUIRED/OPTIONAL ATTRIBUTE. Fields may be designated as "required" or "optional". As shown in figure 5-6, this attribute is specified by way of the field definition menu. When the terminal operator presses either the GIll

key or a user-defined function key that transmits a block of data to the host computer, the terminal checks all No embedded spaces; Right justified;

only one decimal leading sign if point; plus sign present) .is Jeft (if present) must justified; leading immediately precede spaces changed to

most significant zeros

No embedded spaces; Right justifed;

only one decimal if there is no point; plus sign explicit decimal (if present) must point, the implied immediately precede decimal point is most significant inserted at the digit; minus sign proper position;

(if present) must leading sign (if

immediately precede present) is left

(

most significant justified; leading digit or immediately spaces changed to

follow least zeros

"required" fields to be sure that they contain data. If one is ( found to be empty, then the keyboard is "locked", the bell is sounded, the cursor moves to the offending field, and an error message appears at the bottom of the screen. To correct the situation, press _ and then enter suitable data into the field.

JUSTIFY/NO JUSTIFY ATTRIBUTE. For those types of fields which do not include automatic field editing (all characters, alphabetic, auto-upshift, alphanumeric, in-teger, signed deciinal, and numeric), you may select the

"JUST I FY" attribute which causes any data within the field to be automatically justified whenever the cursor leaves the field. Like the optional/required attribute, this at-tribute is specified by way of the field definition menu. For all characters, alphabetic, auto-upshift, and alphanumeric fields, the data is left-justified. For integer, signed decimal, and numeric fields, the data is right-justified. The jus-tify/nojustify attribute is ignored for implied decimal, con-stant, integer fill, signed decimal fill, and implied decimal fill fields.

TOTAL FILUNO TOTAL FILL ATTRIBUTE. For any type of field (except, of course, constant fields) you m.a,y specify "TOTAL FILL" attribute. This attribute signifies that, if any character position within the field contains a valid character, then every character position within the field must contain a valid character. Like the optional/required and justify/no justify attributes, this at-tribute is specified by way of the field definition menu. The

"TOTAL FILL" attribute is checked as the cursor is about to leave the field. If"TOTAL FILL" is in effect and all character positions of the field do not contain valid characters, then the keyboard is "locked", the bell is sounded, the cursor moves to tp.e start of the field, and an error message ap-pears at the bottom of the screen. To correct the situation, press _ and then enter the data item in a manner which ensures that all character positions contain a valid char-acter (right justify it and include leading zeros, for example, for the numeric field types).

Defining Fields From the Keyboard

From the keyboard, you specify the desired field type and explicit attributes using a menu which you access using the following keystroke sequence:

Dans le document Station 2624A (Page 49-52)

Documents relatifs