z/OS ISPF Dialog Tag Language Guide and Reference
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Defining the application command table

z/OS ISPF Dialog Tag Language Guide and Reference
SC19-3620-00

The tags you use to define an application command table are:
CMDTBL
Begins the definition of an application command table. The required end tag ends the definition.
CMD
Defines a command within an application command table. You code the CMD tags within a CMDTBL definition (between the start and end tags).
CMDACT
Defines the action taken by ISPF when a user enters a command. You code the CMDACT tag following the command (CMD) with which it is associated.

The CMDTBL tag has a required APPLID attribute that you use to define the application identifier for the command table. ISPF uses the value you assign with the APPLID attribute to identify the command table. The value you assign to APPLID must be the same as the runtime application identifier specified when the application starts.

The value you assign as an application identifier can have a maximum of 4 characters, and the first character must be A-Z, a-z, @, #, or $.

Any remaining characters can be either A-Z, a-z, @, #, $ or 0-9. Lowercase characters are translated to their uppercase equivalents. Additionally, ISPF reserves the application identifier ISPx, where x is any character including the space character. Do not use any of these for an APPLID value.

The conversion utility uses the application identifier as a prefix to the string CMDS to form the name of the command table library. For example, the APPLID value, demo, results in the application command table name DEMOCMDS.

Command tables are updated using ISPF table services. Input is obtained from the ISPTLIB DDname allocation and output is written to the ISPTABL DDname allocation. For the description of how to allocate libraries before you start ISPF, and for more information about the use of ISPTLIB and ISPTABL, see the z/OS ISPF User's Guide Vol I.

When a user enters a command in a command-entry field or through a pull-down choice or function key, ISPF searches the command tables defined for the user. The tables are searched in this order (provided that a table is present and defined):

  1. Application command table
  2. User command tables
  3. Site command tables
  4. System command table
Note: Up to three user and site command tables can be defined in the ISPF Configuration table. The search order of the site and system command table can be reversed if specified as such in the ISPF Configuration table.

If the command is found in a command table, ISPF performs the action defined in that command table for that command. If the command is not found in any of the command tables, ISPF passes the command to the application program for processing. If any of the command tables are not present, ISPF skips to the next command table in the hierarchy.

Use the CMD tag to define each of the commands within the application command table. The CMD tag has a required NAME attribute that you use to identify the internal-command-name for the command. The value you assign as an internal-command-name must not exceed 8 characters, and the first character must be alphabetic. Any remaining characters can be either alphabetic or numeric.

Here is a markup example that shows a source file that contains an application command table, a key mapping list, and a panel with an action bar. The command table contains commands that are mapped to the RUN attributes of the ACTION tags associated with the pull-down choices and to the CMD attributes of the KEYI tags.
<!doctype dm system>

<cmdtbl applid=brws>
  <cmd name=quit>quit
    <cmdact action=...>
  <cmd name=send>send
    <cmdact action=...>
</cmdtbl>

<keyl name=panlkeys>
  <keyi key=f4 cmd=quit>
  <keyi key=f6 cmd=send>
</keyl>

<panel...>
  <ab>
    <abc>Actions
      <pdc>Quit
        <action run=quit>
      <pdc>Send
        <action run=send>
      <pdc>Exit
        <action run=exit>
  </ab>
⋮
</panel>

Because ISPF provides the EXIT command, it is not defined within the application command table. When the EXIT command is entered, ISPF finds it in the system command table.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014