Previous Topic: 3.3.6.1 ISPF LIBDEF Service Overview

Next Topic: 3.3.6.3 Alternative Online Facilities Implementation

3.3.6.2 Sample CA MICS Online Facilities Implementation



    %-------------------  ISPF MASTER APPLICATION MENU  --------------------
    %OPTION ====>_ZCMD                                                     +
    %
    %   1 +CA MICS     - CA MICS Workstation Facility
    %   2 +.           - (Description for option 2)
    %   3 +.           - (Description for option 3)
    %   4 +.           - (Description for option 4)
    %   5 +.           - (Description for option 5)
    %   X +EXIT        - Terminate ISPF using list/log defaults

    +Enter%END+command to terminate ISPF.
    %
    )INIT
      .HELP    = ISP00005     /* Help for this master menu             */
      &ZPRIM   = YES          /* This is a primary option menu         */
    )PROC
      &ZSEL = TRANS( TRUNC (&ZCMD,'.')
         1,'CMD(%MWF)'
           /*******************************************************/
           /*                                                     */
           /* Add other applications here.                        */
           /*                                                     */
           /*******************************************************/
           /* Following shows how to code an invocation of the    */
           /* ISPF Program Development Facility, where "n" is     */
           /* the desired selection number:                       */
           /*                                                     */
           /*  n,'PANEL(ISR@PRIM) NEWAPPL(ISR)'                   */
           /*                                                     */
           /*******************************************************/
        ' ',' '
          X,'EXIT'
          *,'?' )
    )END

CA MICS online facilities are accessed through a CLIST which
is invoked from an ISPF menu.  The CLIST allocates CA MICS
ISPF software libraries with the TSO ALLOCATE command,
invokes the ISPF library definition (LIBDEF) service, and
starts the CA MICS Workstation Facility (MWF) with the ISPF
SELECT service.

In this sample, we show the CA MICS option on your ISPF
master application panel, ISP@MSTR (see the example above).
The panel option executes a CLIST called MWF from your
installation's ISPF dialog CLIST library.  That is, the MWF
clist is placed in a site-dependent library that is allocated
to the SYSPROC DDNAME.  The member name of this CLIST is MWF.
If you use a different name, the selection coded on the menu
should be changed accordingly.

In selecting the CLIST from the menu, DO NOT include a
NEWAPPL keyword at this point.  The NEWAPPL(MWF) keyword must
be specified at the point when the CA MICS Workstation
Facility is selected from the CLIST, using the ISPEXEC SELECT
service.  This method is required so that the MWFCMDS table
is available from ISPTLIB at the point when the MWF
application is started.  This also means that the LIBDEF
environment is established from the calling application,
which should not itself be a LIBDEF environment.
Sample 1, CA MICS invocation with ISPF and PDF in SYS1.LPALIB

This sample assumes that the ISPF and PDF programs are
located in STEPLIB, the SYS1.LPALIB library, or the MVS link
list, and therefore are not accessed through the ISPLLIB
concatenation.  See the second sample if you use ISPLLIB to
access ISPF and PDF.  In this sample, "sasprefix.sas.library"
refers to the SAS load library data set name you specified in
the sharedprefix.MICS.PARMS(JCLDEFC) SASLIB parameter.  See
sharedprefix.MICS.CLIST(MWFSMPL1) for the generated version
of this sample CLIST.


   ISPEXEC TBSTATS MWF$STAT STATUS3(STATUS3)
   IF &STATUS3 NE 1 THEN GOTO NOALLOC
   CONTROL NOMSG
   FREE FI(MICSLIB MWFPLIB MWFMLIB MWFSLIB MWFTLIB)
   CONTROL MSG
   ALLOC FI(MICSLIB) SHR DA('sharedprefix.MICS.LOAD' +
                            'sasprefix.sas.library')
   ALLOC FI(MWFPLIB) SHR DA('sharedprefix.MICS.ISPPLIB' +
                            'sharedprefix.MICS.ISPHLIB')
   ALLOC FI(MWFMLIB) SHR DA('sharedprefix.MICS.ISPMLIB')
   ALLOC FI(MWFSLIB) SHR DA('sharedprefix.MICS.ISPSLIB')
   ALLOC FI(MWFTLIB) SHR DA('sharedprefix.MICS.ISPTLIB')
   NOALLOC: +
   ISPEXEC LIBDEF ISPLLIB LIBRARY ID(MICSLIB)
   ISPEXEC LIBDEF ISPPLIB LIBRARY ID(MWFPLIB)
   ISPEXEC LIBDEF ISPMLIB LIBRARY ID(MWFMLIB)
   ISPEXEC LIBDEF ISPSLIB LIBRARY ID(MWFSLIB)
   ISPEXEC LIBDEF ISPTLIB LIBRARY ID(MWFTLIB)
   ISPEXEC SELECT PGM(MADA) PARM(NEXTFUNC=STARTUP) +
     NEWAPPL(MWF) PASSLIB
   ISPEXEC LIBDEF ISPLLIB ID(MICSLIB)
   ISPEXEC LIBDEF ISPPLIB ID(MWFPLIB)
   ISPEXEC LIBDEF ISPMLIB ID(MWFMLIB)
   ISPEXEC LIBDEF ISPSLIB ID(MWFSLIB)
   ISPEXEC LIBDEF ISPTLIB ID(MWFTLIB)
   ISPEXEC TBSTATS MWF$STAT STATUS3(STATUS3)
   IF &STATUS3 NE 1 THEN GOTO NOFREE
   FREE FI(MICSLIB MWFPLIB MWFMLIB MWFSLIB MWFTLIB)
   NOFREE: +
   EXIT CODE(0)

Sample 2, CA MICS invocation with ISPF and PDF in ISPLLIB:

This sample assumes that the ISPF and PDF programs are
accessed through the ISPLLIB DDNAME concatenation.  Because
LIBDEF logically replaces the ISPLLIB allocation, you must
include your ISPF and PDF program libraries in the CA MICS
ISPLLIB concatenation as shown below.  In this sample,
"sasprefix.sas.library" refers to the SAS load library data
set name you specified in the SASLIB parameter of
sharedprefix.MICS.PARMS(JCLDEFC).  See the MWFSMPL2 member of
sharedprefix.MICS.CLIST for the generated version of this
sample CLIST.


   ISPEXEC TBSTATS MWF$STAT STATUS3(STATUS3)
   IF &STATUS3 NE 1 THEN GOTO NOALLOC
   CONTROL NOMSG
   FREE FI(MICSLIB MWFPLIB MWFMLIB MWFSLIB MWFTLIB)
   CONTROL MSG
   ALLOC FI(MICSLIB) SHR DA('sharedprefix.MICS.LOAD' +
                             'sasprefix.sas.library' +
                            'ISP.SISPLOAD' +
                            'ISP.SISLPA')
   ALLOC FI(MWFPLIB) SHR DA('sharedprefix.MICS.ISPPLIB' +
                            'sharedprefix.MICS.ISPHLIB')
   ALLOC FI(MWFMLIB) SHR DA('sharedprefix.MICS.ISPMLIB')
   ALLOC FI(MWFSLIB) SHR DA('sharedprefix.MICS.ISPSLIB')
   ALLOC FI(MWFTLIB) SHR DA('sharedprefix.MICS.ISPTLIB')
   NOALLOC: +
   ISPEXEC LIBDEF ISPLLIB LIBRARY ID(MICSLIB)
   ISPEXEC LIBDEF ISPPLIB LIBRARY ID(MWFPLIB)
   ISPEXEC LIBDEF ISPMLIB LIBRARY ID(MWFMLIB)
   ISPEXEC LIBDEF ISPSLIB LIBRARY ID(MWFSLIB)
   ISPEXEC LIBDEF ISPTLIB LIBRARY ID(MWFTLIB)
   ISPEXEC SELECT PGM(MADA) PARM(NEXTFUNC=STARTUP) +
     NEWAPPL(MWF) PASSLIB
   ISPEXEC LIBDEF ISPLLIB ID(MICSLIB)
   ISPEXEC LIBDEF ISPPLIB ID(MWFPLIB)
   ISPEXEC LIBDEF ISPMLIB ID(MWFMLIB)
   ISPEXEC LIBDEF ISPSLIB ID(MWFSLIB)
   ISPEXEC LIBDEF ISPTLIB ID(MWFTLIB)
   ISPEXEC TBSTATS MWF$STAT STATUS3(STATUS3)
   IF &STATUS3 NE 1 THEN GOTO NOFREE
   FREE FI(MICSLIB MWFPLIB MWFMLIB MWFSLIB MWFTLIB)
   NOFREE: +
   EXIT CODE(0)