IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Write code which would open the PS


IBM Mainframe Forums -> TSO/ISPF
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Akash Sharma

New User


Joined: 13 Jan 2009
Posts: 36
Location: India

PostPosted: Wed May 06, 2009 11:37 am
Reply with quote

HI,

I HAVE CODED A PANEL IN ISPF WHICH IS AS BELOW:

Code:

.  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .  .
------------------------------ LOC CALCULATOR-----------------------
COMMAND ===>                                                                   
                                                                               
                                                                               
                    ============INPUT SECTION=====                     
                                                                               
 ENTER PDS NAME  ==> CAM.SCM.CLIB                                             
                                                                               
 ENTER OUTPUT REPORT LOCATION  ==> NUAGS92.PDS.LISTA
                                                                               
                                                                               
                    ===========OUTPUT SECTION============   
                                                                               
 TOTAL NUMBER OF PROGRAMS IN PDS:  36                                         
                                                                               
 TOTAL NUMBER OF LOC IN PDS:  5167                                             
                                                                               
 PLEASE NOTE:                                                                 
                                                                               
 DETAILED REPORT PRESENT AT:  NUAGS92.PDS.LISTA                 


Is it possible to write code, which would open the PS (NUAGS92.PDS.LISTA) on putting the cursor over the name and pressing some key. I guess it should be possible but please suggest a function which could help me do that.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Wed May 06, 2009 12:15 pm
Reply with quote

Here's an ISPF edit macro to browse the dataset that is specified on the same line as the cursor. The dataset name is located by DSN=

Don't know if you can adapt it to your needs, but good luck.
Code:

/* REXX *** BROWSE DATASET DELIMITED BY DSN= ON THE CURSOR LINE      */
"ISREDIT MACRO"                                                       
"ISREDIT (CRSLINE) = "CURSOR                                           
"ISREDIT (INDATA) = LINE " CRSLINE                                     
INDATA = TRANSLATE(INDATA,' ',',=')                                   
PX = WORDPOS('DSN',INDATA)                                             
IF PX > 0                                                             
  THEN "ISPEXEC BROWSE DATASET('"WORD(INDATA,PX+1)"')"                 
Back to top
View user's profile Send private message
Akash Sharma

New User


Joined: 13 Jan 2009
Posts: 36
Location: India

PostPosted: Wed May 06, 2009 7:16 pm
Reply with quote

Thanks Expat.
The information is quite handy.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> TSO/ISPF

 


Similar Topics
Topic Forum Replies
No new posts run rexx code with jcl CLIST & REXX 15
No new posts Write line by line from two files DFSORT/ICETOOL 7
No new posts Compile rexx code with jcl CLIST & REXX 6
No new posts Calling an Open C library function in... CICS 1
No new posts REXX code to expand copybook in a cob... CLIST & REXX 2
Search our Forums:

Back to Top