MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

REXX interaction with ISPF

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF
View previous topic :: View next topic  
Author Message
to_agrawals
Beginner


Joined: 12 Dec 2002
Posts: 26
Topics: 16

PostPosted: Mon Jun 23, 2003 2:11 am    Post subject: REXX interaction with ISPF Reply with quote

Hi,
We wish to drive the flow of an online application through REXX. The online app is using ISPF panels as the front end. Is it possible to pass values to this app and then simulate enter to go to next screen. The values can be stored initially in some temp variables.

Alternatively, can a simple procedure of going to option 3.4 (from the main menu screen) and putting the dataset name for retrieval be done through REXX..?

I need details on how to interact with ISPF panels through REXX. Please help.

Thanks
Saurabh
Back to top
View user's profile Send private message Send e-mail
dorkhead
Beginner


Joined: 07 Jan 2003
Posts: 25
Topics: 0
Location: Lux

PostPosted: Wed Jun 25, 2003 3:42 am    Post subject: Reply with quote

you can
1 create your own copy of panel you want to display with .resp=ENTER in the
init section of that panel
2 fill variables required by ispf in your REXX
3 call display of panel in your REXX

here is some code that displays SPACE on a volume using ISPF 3.4 listing :


Code:

 /* REXX */                                                       
 arg vol                                                           
 trace off                                                         
 address tso                                                       
 "free fi(junk)"                                                   
 "free fi(junk1)"                                                 
 if vol = '' then do until vol ^= ''                               
                  say 'plz enter a volume or exit '               
                  pull vol                                         
                  end                                             
 if vol=exit then exit                                             
  else nop                                                         
  zddnvol=vol                                                     
  zddnskp='0'                                                     
  "ALLOC FI(JUNK) DA('"USERID()".TEMP.PANEL') NEW DELETE TRACK     
  SPACE(2 1) RECFM(F B) LRECL(80) BLKSIZE(3120) DIR(1)"           
  "ALLOC FI(JUNK1) DA('"USERID()".TEMP.PANEL(udlp)') shr reuse "   
/* this is the panel */
 queue ")ATTR "                                     
 queue "? type(output) "                           
 queue ")body cmd()    "                           
 queue "_zcmd      +?ZDLPVL+"                       
 queue ")init "                                     
 queue "VGET (ZDDNVOL) shared "                     
 queue "&zcmd = &Z "                               
 queue "&zuopt= V "                                 
 queue "&zDLPVL= &ZDDNVOL "                         
 queue "IF (&ZDDNSKP NE '1') .RESP = ENTER"         
 queue "ELSE .RESP = END "                         
 queue "&zddnskp= '1'    "                         
 queue ")reinit "                                   
 queue ".RESP = END "                               
 queue ")proc       "                               
 queue ")end        "     
/* en of panel */                         
 say queued()     
 address ispexec                             
   "LMINIT DATAID(DID) DDNAME(junk)"         
   "LIBDEF ISPPLIB library id(junk)"         
 "control errors return"                     
 "control nondispl enter"                   
 "vput (zddnvol) shared"                     
 "vget (zdlpvl)"                             
 oldvol=ZDLPVL                               
 "select pgm(isrudl) parm(udLp)"             
 zdlpvl=oldvol                               
 "vput (zdlpvl)"                             
 "lmfree dataid("did")"                     
 "libdef ISPPLIB"                           
 address tso                                 
 "free fi(junk)"                             
 "free fi(junk1)"                           
 exit 1                                     



this example works for me ....

it serves as an example of what I said.

I suggest first you find the name of panel u want to use first
find where they are, view them

and make a copy somewhere.

also as we say RTFM, it may help here.

have fun
_________________
Dorkhead
Back to top
View user's profile Send private message Visit poster's website
to_agrawals
Beginner


Joined: 12 Dec 2002
Posts: 26
Topics: 16

PostPosted: Wed Jul 16, 2003 7:11 am    Post subject: Reply with quote

Thanks Dork,
I was just going through your reply. Sorry for being so late in responding. Actually, after going further deep into the application, I have infered the following:
In my application, the .resp=ENTER code does occur in the init section of each panel. It is a PL/I code which is the ISPF driver and retreives the panel variables. If I try to simulate the enter key through REXX, after supplying the panel values in REXX, I am merely able to drive the ISPF panels and not the actual application. I need to somehow interact with this PL/I code also through REXX so as to make sure that all other functions performed by this PL/I code goes as it was doing before.

Please help and let me know if more inputs are required from my end.

Thanks
Saurabh
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group