Finding out about your terminal
Some applications must support more than one type of terminal, and sometimes the types are sufficiently different that they require separate code. If you are writing such a program, and you need to determine what sort of terminal it is currently communicating with, you can use the ASSIGN command to find out.
ASSIGN returns a variety of information about the executing task, including a number of fields that describe its principal facility. Table 1 lists the ones that relate directly to terminal control operations. There are other ASSIGN options that relate to BMS and to other aspects of the task. You can find details on all ASSIGN options in CICS command summary . The “terminal” cited in column 2 of the table is always the principal facility of the task.
| ASSIGN option | Information returned |
|---|---|
| ALTSCRNHT |
The alternate height and width of the terminal screen (from its terminal definition); see also SCRNHT and SCRNWD |
| APLKYBD | Whether terminal has an APL keyboard |
| APLTEXT | Whether terminal has the APL text feature |
| BTRANS | Whether terminal has background transparency capability |
| COLOR | Whether terminal has extended color capability |
| DEFSCRNHT |
The default height and width of the terminal screen (from its terminal definition); see also SCRNHT and SCRNWD |
| DELIMITER | The data-link control character for the terminal (for 3600 terminals only) |
| DESTID |
The identifier of the outboard destination and its length (for BDI operations only) |
| DSSCS | Whether the terminal is an SCS data stream device |
| DS3270 | Whether the terminal is a 3270 data stream device |
| EXTDS | Whether the terminal supports “query structured field” orders |
| EWASUPP | Whether the terminal supports “erase write alternate” orders (i.e. has alternate screen size capability) |
| FACILITY | The 4-character identifier of the terminal |
| FCI | The type of principal facility associated with the task (terminal, queue, and so on) |
| GCHARS |
The graphic character set global identifier and the code page global identifier associated with the terminal |
| HILIGHT | Whether the terminal has extended highlight capability |
| KATAKANA | Whether the terminal supports Katakana |
| LANGINUSE | The 3-character mnemonic |
| MSRCONTROL | Whether the terminal supports magnetic slot reader control |
| NATLANGINUSE | The national language in use for the current task |
| NETNAME | The 8-character identifier of the terminal in the SNA network |
| NUMTAB | Number of tabs required to position the print element in the correct passbook area (for 2980s only) |
| OPID |
Operator identifier code and operator class of user signed on at terminal |
| OUTLINE | Whether the terminal has field outlining capability |
| PARTNS | Whether the terminal supports screen partitions |
| PS | Whether the terminal has programmed symbols capability |
| SCRNHT |
Height and width of the terminal screen for the current task |
| SIGDATA | SIGNAL data received from the terminal |
| SOSI | Whether the terminal has mixed EBCDIC/double-byte character set capability |
| STATIONID |
Station and teller identifier of the terminal (for 2980s only) |
| TERMCODE | Type and model number of the terminal |
| TERMPRIORITY | Terminal priority value |
| TEXTKYBD | Whether the terminal has the TEXTKYBD feature |
| TEXTPRINT | Whether the terminal has the TEXTPRINT feature |
| UNATTEND | Whether the terminal is unattended |
| USERID |
The 8-character identifier, 20-character name and priority of the user signed on at the terminal |
| VALIDATION | Whether the terminal has validation capability |
You can also use the INQUIRE TERMINAL command to find out about your own terminal or any other terminal. INQUIRE TERMINAL returns information from the terminal definition, whereas ASSIGN describes the use of that terminal in the current task. For many options, however, particularly the hardware characteristics, the information returned is the same.