Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

How to process the input given from the ISPFpanel

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
syed-sameer-ahmed
Warnings : 2

New User


Joined: 22 Feb 2007
Posts: 46
Location: Bangalore

PostPosted: Sat Jan 17, 2009 9:33 am    Post subject: How to process the input given from the ISPFpanel
Reply with quote

Hello All,

I have created a ISPF panel
Code:


'ISREDIT MACRO'                                                 
                     
TRACE ?R                                                       
ADDRESS ISPEXEC "LIBDEF ISPPLIB DATASET ID(SYED.TOOL.PANEL')"
ADDRESS ISPEXEC "DISPLAY PANEL(ABC)"   

                         
                         
                                           


This is the code for the ISPF panel

Code:

)ATTR                                                                     
  + TYPE(TEXT)   INTENS(LOW)         SKIP(ON)                             
  % TYPE(TEXT)   INTENS(HIGH) SKIP(ON)                                     
  _ TYPE(INPUT)  INTENS(HIGH) CAPS(ON) HILITE(USCORE) COLOR(WHITE)         
  \ TYPE(OUTPUT) INTENS(HIGH)                                             
  # TYPE(OUTPUT) INTENS(HIGH) JUST(RIGHT)                                 
        TYPE(TEXT)   INTENS(LOW)  SKIP(ON)                                 
  $ TYPE(TEXT)   INTENS(HIGH) SKIP(ON)                                     
  ~ TYPE(INPUT)  INTENS(HIGH) CAPS(ON)                                     
)BODY EXPAND(::)                                                           
%COMMAND ===>_ZCMD                                                         
+                   === REXX ABEND UTILITY SYSTEM  ===                     
+      ==== VIEW OR BROWSE A DATASET OR FILE OR MEMBER     ====           
+                                                                         
    ENTER THE NODE NAME ==>_INF                                           
+
+       1.ABC    2.XYZ+                                                                         

+   ENTER THE MEMBER TYPE==>_INMEM   

+                                                                       
+           1.CPY      2.SRC     3.CTL   4.PRC    5.EXC                 
+                                                                       
+           6.EXP      7.JCL     8.INC   9.RD                           
+                                                                       
    INPUT MEMBER NAME   ==>_INSTR                                       
                                                                         
+                                                                       


                                     
)MODEL                                                                 
+                                                                     
)INIT                                                                 
  &INF      = ''                                                       
  &OUTF     = ''                                                       
  &INSTR    = ''                                                       
  &INMEM    = ''                                                       
  &OUTSTR   = ''                                                       
  &KEYNUM   = .PFKEY                                                   
  &ZTDMARK  = '---------------------------------------------+         
               ----------------------------------'                     
)PROC                                                                 
VER (&INF, NB)                                                       
VER (&OUTF, NB)                                                       
VER (&INSTR, NB)                                                     
VER (&INMEM, NB)                                                     
IF (&OUTF = &INF)                                                     
   &OUTF  = '***ERROR: INPUT NAME = OUTPUT NAME ***'                 
IF (&KEYNUM = 'PF03')                                                 
   &NOMORE  = 'Y'                                                     
    &NOMORE  = 'Y'
 )END           

 


My query is on prcessing the input from the panel.

if I enter 1 at _INF it should select ABC PDS and similarly if INMEM =1 it select copy books.

I wanted to know like when I enter this data,how to open the dataset in different or same panel.

1)Do I need to define a variable?
2)How is the variable defined and how do I refer it in the Rexx program?
3)Are INF,INSTR and INMEM are defined by me as I do not if some Inbuilt variable or names exists ?

Sample code is Appreciated.Just for understanding as I am a beginner.

Thanks

Syed Sameer Ahmed
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Sat Jan 17, 2009 12:49 pm    Post subject:
Reply with quote

If you use the same name for the variables in the panel and REXX there is no problem.

The variable is created in either the panel or the REXX and can be passed between the two once it has been created.
Back to top
View user's profile Send private message
syed-sameer-ahmed
Warnings : 2

New User


Joined: 22 Feb 2007
Posts: 46
Location: Bangalore

PostPosted: Sat Jan 17, 2009 12:57 pm    Post subject:
Reply with quote

Thanks Expat,but does that mean If I am using ==>_INF in panel.The same can be used in a Rexx progrm for comparisons and conditional execution.

ex: if INF=1 then
View dataset "ABC.CPY"

Will similar stuff like this work..

and I also want to view the PDS and once PF3 is pressed the Panel should be displayed again similar to file-aid and I am not able to get a sample code or example on how to use,nor any material related to PANEL and REXX integration.

Thanks
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Sat Jan 17, 2009 1:02 pm    Post subject:
Reply with quote

Quote:
Thanks Expat,but does that mean If I am using ==>_INF in panel.The same can be used in a Rexx progrm for comparisons and conditional execution.
ex: if INF=1 then
View dataset "ABC.CPY"

Correct

Use the manuals button at the top of the page to get to the REXX and ISPF manuals.
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2019
Location: Silicon Valley

PostPosted: Sun Jan 18, 2009 10:12 pm    Post subject: Reply to: How to process the input given from the ISPFpanel
Reply with quote

Display the panel within a loop. Check the return code from the DISPLAY service. If 8 or higher, exit the loop.
Back to top
View user's profile Send private message
syed-sameer-ahmed
Warnings : 2

New User


Joined: 22 Feb 2007
Posts: 46
Location: Bangalore

PostPosted: Tue Jan 27, 2009 1:07 pm    Post subject:
Reply with quote

I am able to process numerics from Panel but not any alpha data like ABC.
It also diplay "Missing field definition " in the panel..

Please help how to remove this bugs.

Thanks
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Tue Jan 27, 2009 1:26 pm    Post subject:
Reply with quote

Have you tried the panel trace facility ISPDPTRC - documented in the fine manuals
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2019
Location: Silicon Valley

PostPosted: Tue Jan 27, 2009 9:53 pm    Post subject: Reply to: How to process the input given from the ISPFpanel
Reply with quote

Quote:
I am able to process numerics from Panel but not any alpha data like ABC.
It also diplay "Missing field definition " in the panel..


More details please:
1. which field are you talking about?
2. What do you mean by 'process'?
3. What is the message id of the 'missing field definition' message?
Back to top
View user's profile Send private message
syed-sameer-ahmed
Warnings : 2

New User


Joined: 22 Feb 2007
Posts: 46
Location: Bangalore

PostPosted: Thu Jan 29, 2009 7:36 pm    Post subject:
Reply with quote

Hello All,

Thanks for all your help.Your icon_biggrin.gif helping nature made me learn many things.
I was able to resolve many things by your suggestions and help.

I have few things to understand as
1) where and how is the Message Id displayed
2) I have concatenated the dataset in the RExx as
Code:

NODE=ABC.CPY.||INF||P.XYZ
MEMBER=NODE||'('||INSTR||')'   
     

where INF = PQR and INSTR= HIJ
I get the Member as ABC.CPY.PQRP.XYZ(HIJ)

but I am not able to browse the concatenated dataset using
Code:

       
IF SYSDSN(MEMBER) = 'OK' THEN   
      DO                         
       "VIEW DATASET(MEMBER)"   
      END


Could any body help me with as what is wrong in referencing the member in SYSDSN.
Why is the Concatenation is not substituted in place of Member?

Kindly let me know if it perplexing.

Thanks
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2019
Location: Silicon Valley

PostPosted: Thu Jan 29, 2009 9:51 pm    Post subject: Reply to: How to process the input given from the ISPFpanel
Reply with quote

Rexx will not substitute anything within quotes. You probably want something like this:
Code:
"VIEW DATASET("MEMBER")"
Back to top
View user's profile Send private message
syed-sameer-ahmed
Warnings : 2

New User


Joined: 22 Feb 2007
Posts: 46
Location: Bangalore

PostPosted: Tue Feb 03, 2009 2:39 pm    Post subject:
Reply with quote

Hello Good People,

Thanks for all your answers and help.

How can I leave a field as optional.I have three fields in panel.
1) INSTR
2) INMEM
3) INF

I want all fields to be optional.

Code:


 ENTER THE NODE NAME ==> _INSTR                               
         1.ABC      2.DEF     3.GHI     4.JKL     5.MNP
                                                       
                                                                 
 ENTER THE MEMBER TYPE==> _ INMEM                             
                                                       
         1.CPY      2.SRC     3.CTL   4.PRC    5.EXC   
                                                       
         6.EXP      7.JCL     8.INC   9.RD             
                                                       
 INPUT MEMBER NAME   ==> _ INF



How should a variable be defined for these.

I have defined the variable as

Code:
)
MODEL                                                                   
+                                                                         
)INIT                                                                     
  &INF      = ''                                                         
  &INSTR    = ''                                                         
  &INMEM    = ''                                                         
  &KEYNUM   = .PFKEY                                                     
  &ZTDMARK  = '---------------------------------------------+             
               ----------------------------------'                       
)PROC                                                                     
VER (&INF,NB)                                                             
VER (&INSTR,NB)                                                           
VER (&INMEM,NB)                                                           
IF (&KEYNUM = 'PF03')                                                     
   &NOMORE  = 'Y'                                                         
)END                                                                     
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2019
Location: Silicon Valley

PostPosted: Tue Feb 03, 2009 10:06 pm    Post subject: Reply to: How to process the input given from the ISPFpanel
Reply with quote

If I recall correctly, these statements:
Code:

VER (&INF,NB)   
VER (&INSTR,NB)
VER (&INMEM,NB) 

Require that the values be non-blank. If you want to allow blanks, then remove these statements.
Back to top
View user's profile Send private message
syed-sameer-ahmed
Warnings : 2

New User


Joined: 22 Feb 2007
Posts: 46
Location: Bangalore

PostPosted: Thu Feb 05, 2009 8:12 am    Post subject: Problem with the View command
Reply with quote

Hello ,

I have debugged and my tool was working fine but now I am getting a error message as

" IKJ56500I COMMAND VIEW NOT FOUND
"VIEW DATASET('ABCD.XYZ.CPY("INSTR")')"

Please help me out as why "VIEW" command is not working now.

Thanks
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Thu Feb 05, 2009 8:19 am    Post subject:
Reply with quote

Hello,

What was changed between the last time this worked and now that it does not?
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2019
Location: Silicon Valley

PostPosted: Fri Feb 06, 2009 5:15 am    Post subject: Reply to: How to process the input given from the ISPFpanel
Reply with quote

Should use Address ISPEXEC rather that Address ISREDIT.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts High CPU consumption Job using IAM fi... aswinir JCL & VSAM 8 Thu Dec 01, 2016 8:28 pm
This topic is locked: you cannot edit posts or make replies. How to use 2 input files in control c... Gunapala CN DFSORT/ICETOOL 23 Thu Oct 13, 2016 3:42 pm
No new posts How to copy PDS using dataset as input Ayodhya prasad JCL & VSAM 5 Wed Jun 01, 2016 6:02 pm
No new posts Need Help to Define 36 Input Fields (... satish.ms10 CLIST & REXX 2 Sat May 07, 2016 3:08 pm
No new posts No TSO prefix doesn't get the input boyti ko CLIST & REXX 4 Thu Apr 28, 2016 3:31 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us