Writing a program that uses the command interface: An
example
Suppose you want to use the command interface to display an ISPF panel
that prompts a user to specify a query name, runs the query, and
displays a report.
For this scenario, do the following:
- Write your command interface REXX program. Your program does the following:
- Displays the ISPF panel QRYNAME using the DISPLAY services:
ADDRESS ISPEXEC "DISPLAY PANEL(QRYNAME)"
- Runs a QMF query based on user input from the previous DISPLAY service.
Here, the ISPF variable QNAME contains the name of the QMF query:
ADDRESS ISPEXEC "SELECT PGM(DSQCCI) PARM(RUN QUERY" QNAME ")"
- Lets the user view the result of the query, using the following
command:
ADDRESS ISPEXEC "SELECT PGM(DSQCCI) PARM(INTERACT)"
- Start ISPF.
- Start QMF.
- Call your program using the CMS or TSO command from the QMF command
line. For example, if your program is named GETINFO, your command
looks like one of the following depending on your system:
CMS GETINFO
TSO GETINFO
