You are here: Development Standards > Upgrading OSAS > Converting to 6.xx Graphical > Other Resource Standards

# Other Resource Standards

Whether you are designing new screens or modifying existing ones, keep these standards in mind:

1. All controls dealing with user input start at control ID 4000 and increase by 10. The control numbers coincide with the order that the fields are being used within the existing program. The increments of 10 allow you room to add controls between the existing fields. If you add fields, the control ID must fall between the control IDs that already exist.
2. All programs that work with OSAS must use the form flags and event masks as laid out in these standards. Using other flags and event masks may result in unpredictable behavior.

Other Control Standards

OSAS also uses controls that are defined by systems programs and that are not stored in resource files:

Control ID | Usage
20000-200130 | Commands menu (Inquiry, Maintenance, etc.)
20050-20053 | Edit menu (Copy, Paste, Undo)
20100-20105 | Modes menu (Verify Exit, Bell, Quick, etc.)
20300-20304 | Help menu (About OSAS, Command Help, etc.)
20200-202xx | Other Commands menu (Calculator, Call BBx program, etc.)
20500-20509 | Scroll region menu (Home, End, Page Up, Delete, etc.)
20550-2055x | Information menu (Shift-F2 menu in character mode)
20600+ | Inventory Shift-function-key menu, Var usage
21000-21200 | Tool Bar - Several types of controls make up the tool bar

Calculation of Field Sizes

Use this table to determine the pixel width of input controls in OSAS screens:

No. of Characters | Multiplier | Extended
1 | 17 | 17
2 | 14 | 28
3 | 13 | 39
4 | 13 | 52
5 | 13 | 65
6 | 13 | 78
7 | 11 | 77
8 | 11 | 88
9 | 11 | 99
10 | 12 | 120
11 | 10 | 110
12 | 10 | 120
13 | 7.5 | 97.5
14+ | 7.5 |

For INPUTE or INPUTN fields, determine how wide to make an entry field by applying the table value corresponding to the character field length. For example, for a field with a character length of 15, calculate the length by multiplying 15 by the multiplier of 7.5 for a result of 112.5 which, when rounded up, becomes 113.

For static text controls, either estimate the space needed by sight, or use the formula above. Then add a few pixels to account for any scaling that may happen if the user turns scaling on.

Using Masks Within Resource Files

You can define the mask that an alphanumeric or numeric field should use within a resource file. You can change these masks from within the code, if necessary.

For an INPUTN control, specify the mask you want to use for the input. Use ‘#’ and ‘0’ to represent numeric characters. If you do not want a ‘0’ to appear if it is entered, use the ‘#’.

For an INPUTE field, the following chart shows the possible values for the mask:

Mask | Function
X | Any printable character
a | Any alphabetic character
A | Any alphabetic character. Converts letters to uppercase.
0 | Any digit
U | Any digit, alphabetic, space, or punctuation. Converts letters to uppercase.
z | Any digit or alphabetic character
Z | Any digit or alphabetic character. Converts letters to uppercase.