Skip to main content
Version: v3.0.x LTS

Using the 3270 Terminal

Using the 3270 Terminal

The 3270 Terminal Display Emulator plug-in provides a user interface that emulates the basic functions of IBM 3270 family terminals. On the back end, the plug-in and the Zowe Application Server connect to any standard TN3270/E server.

This terminal display emulator operates as a three tier program. Due to web browsers being unable to supply TCP networking that terminals require, this terminal display emulator does not connect directly to your TN3270 server. Instead, the Zowe Application Server acts as a bridge, and uses websockets between the server and the browser for terminal communication. As a result, terminal connections only work when the stack of network programs supports websockets and the TN3270 server destination is visible to the Zowe Application Server.

The terminal connection can be customized per user and saved for future sessions using the connection toolbar of the application. The preferences are stored within the configuration dataservice storage, which can also be used to set instance-wide defaults for multiple users.

Keyboard shortcuts

The terminal bundle that is used by tn3270-ng2 has several keyboard shortcuts to execute common TN3270 emulator functionality. The following Action and shortcut table presents the current list of what function is mapped to which key combination.

Be aware that some browsers intercept key combinations that are common to browsers, such as ctrl+R or ctrl+T, and that the operating system may also intercept certain combinations such as Windows+R or alt+F4.

Also, be aware that the key combinations listed are only be handled by the terminal if the terminal has focus, which you can determine if the terminal's cursor is visible and blinking or not. To gain focus on the terminal, it is sufficient to click on the terminal's contents. The difference between focus and not focus may be the difference between F5 being interpreted as terminal PF5, or the browser reloading the page.

Action and Shortcut table

ActionKeyboard ShortcutNote
Back TabShift+Tab
BackspaceBackspace
ClearCtrl+Shift+z
Cursor DownArrowDown, NumpadArrowDown
Cursor LeftArrowLeft, NumpadArrowLeft
Cursor RightArrowRight, NumpadArrowRight
Cursor UpArrowUp, NumpadArrowUp
DeleteDelete, NumpadDelete
EndEnd, NumpadEnd
EnterEnter, NumpadEnter
Erase End of Field (EOF)Ctrl+eErases from cursor position to end of field
Erase FieldCtrl+lErases entire field
Erase InputErases contents of all input fields
Erase WordErases until next word, including whitespace
HomeHome, NumpadHome
InsertInsert, NumpadInsertToggles insert text mode
New LineShift+Enter, Shift+NumpadEnterMoves cursor to field on next row
PA1Alt+1
PA2Alt+2
PA3Alt+3
PF01F1
PF02F2
PF03F3
PF04F4
PF05F5
PF06F6
PF07F7
PF08F8
PF09F9
PF10F10
PF11F11
PF12F12
PF13Shift+F1
PF14Shift+F2
PF15Shift+F3
PF16Shift+F4
PF17Shift+F5
PF18Shift+F6
PF19Shift+F7
PF20Shift+F8
PF21Shift+F9
PF22Shift+F10
PF23Shift+F11
PF24Shift+F12
ResetAlt+rTerminal does not lock on bad input, but rejects and auto resets. No use for reset button currently.
TabTab

Key sequences

Key sequences allow users to define their own key sequences. Each key sequence is a recorded set of keys with the possibility of using the key modifiers (Ctrl, Alt, Shift), function keys (F1, F2, ...) and the combinations (such as Ctrl+E or Shift+F1). The definition is stored in the _keySequences.json file.

Default key sequences

  • There is a set of predefined key sequences
  • Key sequences are accesible via top right menu:

image

Syntax of the JSON

  • All key sequences can be redefined by the user
  • Following syntax is required:
    • keySequences is an array of individual key sequences
    • title displayed in the key sequences menu
    • description is hover help for each item in the key sequences menu
    • keys is an array of the key strokes
      • normal for the "typewriter" keys
      • special for the function, modifiers and other special keys
        • The value corresponds to the javascript key code
      • prompt is used for user input and this input is pasted on the current cursor position
    • ctrl, alt and shift are key modifiers
    • If you combine normal, special or prompt in one array item, only one action will be made in the order of normal, special and prompt

Example

Review the following demonstration on two simple key sequences:

  • Hello, world
    • Types Hello, world only
  • ISPF command SWAP NEXT
    • Presses Home to get on the command line/input field
    • Ctrl+E deletes the input field
      • Ctrl+E is predefined in the TN3270 as "EOF - Erase end of field"
    • Types SWAP NEXT
    • Hits Enter

The corresponding file _keySequences.json appears as the following:

{ "keySequences":
[
{ "title": "Hello, world",
"description": "Types Hello, world",
"keys": [ { "normal": "Hello, world" } ]
},
{ "title": "SWAP NEXT",
"description": "ISPF: Swap next command",
"keys": [ { "special": "Home" },
{ "normal": "E", "ctrl": "true" },
{ "normal": "SWAP NEXT" },
{ "special": "Enter" }
]
}
]
}