Portal | IBM Manuals | Downloads | Products | Refer | Info | Programs | JCLs | Forum Rules*| Site Map | Mainframe CD 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index
 
Register
 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index FAQ Search Memberlist Usergroups Profile Log in to check your private messages Log in
 
use of loop in ispf panel
Goto page 1, 2  Next
 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF
Author Message
JOYEETA PAUL
Warnings : 1

New User


Joined: 18 Sep 2008
Posts: 16
Location: bangalore

PostPosted: Fri Sep 19, 2008 12:13 pm    Post subject: use of loop in ispf panel
Reply with quote

i want to use a loop in ispf panel to read records from a ps file. can anybody help me to give some examples?
Back to top
View user's profile Send private message
References
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 3506
Location: Brussels once more ...

PostPosted: Fri Sep 19, 2008 12:40 pm    Post subject:
Reply with quote

Please explain what you really want to do,

And why do you think that a panel will read the data ?
What is wrong with EXECIO ?
Back to top
View user's profile Send private message
genesis786

Active User


Joined: 28 Sep 2005
Posts: 88
Location: London

PostPosted: Fri Sep 19, 2008 3:42 pm    Post subject:
Reply with quote

I think joyeeta paul wants to understand how to work with page up page down on a panel?

if yes.. then u need to use tables to display multiple page records in a panel.. table (tbcreate, tbadd, tbbottom, tbdispl etc..) will take care of page up page down...

let us know if this is ur doubt!!
Back to top
View user's profile Send private message
JOYEETA PAUL
Warnings : 1

New User


Joined: 18 Sep 2008
Posts: 16
Location: bangalore

PostPosted: Fri Sep 19, 2008 7:25 pm    Post subject:
Reply with quote

ya i know the EXECIO command.i used that one in my rexx prog.but i want to see file records in a panel. actually i have one ps file with more than 1 line of records. now i want to display the records in a panel .so i need a loop to read the records one by one from the file.there will be a limit i.e. end of file.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 3263
Location: Charlotte,NC USA

PostPosted: Fri Sep 19, 2008 7:37 pm    Post subject: Reply to: use of loop in ispf panel
Reply with quote

So, you want to:

Read a record.
Display that record in a panel.
Presumably, wait for some user input, then move on or exit out.
Display the next record.
Continue on until EOF.

Is that about it?
Back to top
View user's profile Send private message
JOYEETA PAUL
Warnings : 1

New User


Joined: 18 Sep 2008
Posts: 16
Location: bangalore

PostPosted: Fri Sep 19, 2008 7:57 pm    Post subject:
Reply with quote

no, all records will in same panel.all records will be displaying in the same panel line by line until end of file.this line by line thing should be in a loop as we use in EXECIO.
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 1930
Location: Israel

PostPosted: Fri Sep 19, 2008 8:59 pm    Post subject:
Reply with quote

You can't read records within ISPF panel (unless you use EXECIO within *REXX within the panel, which is silly).

A dataset can be read using some programming language (to include REXX), and then its content is saved in variables. Then, you may use ISPF panel to display these variables.

o.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 3263
Location: Charlotte,NC USA

PostPosted: Fri Sep 19, 2008 9:29 pm    Post subject: Reply to: use of loop in ispf panel
Reply with quote

I'm probably not the only one confused here. genesis786 has already mentioned using an ISPF Table and storing the records that way, then using a TBDISPL service to display the table in a panel. I'm puzzled as to why you wouldn't just use a BROWSE or EDIT, with or without a panel.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 3263
Location: Charlotte,NC USA

PostPosted: Fri Sep 19, 2008 9:30 pm    Post subject: Reply to: use of loop in ispf panel
Reply with quote

Otherwise, the only other option I can think of is a panel that uses a dynamic area.
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 502
Location: work

PostPosted: Sat Sep 20, 2008 12:29 am    Post subject: Reply to: use of loop in ispf panel
Reply with quote

Normally, you would just want to browse the dataset. Done!

But some datasets have records that are not best for browsing. The easiest is to read your raw data, convert / format into readable records and make a new report dataset and browse that. Still fairly simple. But you loop through your many records and processing them and when done, then do a single display.

Already suggested as a table display. You loop through your many records and processing them and when done, then do a single display. It is not clear why you want the display within a loop.

You can use the BRIF service (browse interface) to browse through your data, but much more complicated because you have to provide some assembler exits.
Back to top
View user's profile Send private message
JOYEETA PAUL
Warnings : 1

New User


Joined: 18 Sep 2008
Posts: 16
Location: bangalore

PostPosted: Sat Sep 20, 2008 1:31 pm    Post subject:
Reply with quote

how can i use a dynamic area in a panel? can you pls explain it with examples?
Back to top
View user's profile Send private message
genesis786

Active User


Joined: 28 Sep 2005
Posts: 88
Location: London

PostPosted: Sat Sep 20, 2008 2:00 pm    Post subject:
Reply with quote

this might help:

http://publibz.boulder.ibm.com/cgi-bin/bookmgr/BOOKS/ISPZDG40/6.4.3.1?SHELF=&DT=20050712212339
Back to top
View user's profile Send private message
genesis786

Active User


Joined: 28 Sep 2005
Posts: 88
Location: London

PostPosted: Sat Sep 20, 2008 2:07 pm    Post subject:
Reply with quote

Using tables you can do something like this:

This is MYPANEL
Code:

)BODY EXPAND(\\)                                                       
+%DATE: ^ZDAT                 @          +                             
+%TIME: ^ZTIM                 @MY PANEL+ ^ZRGN            %USER: ^ZUSR
%CMD+==> _ZCMD                                              %SCROLL+==>
%Env: _Z+ %Country: _Z +%File: _Z      %Key: _Z                         
+-Frm-to------LEVEL/FIELD NAME-------FORMAT----DATA---------------------
)MODEL                                                                 
# rec                  /*This is your variable which will be formed in table */
)INIT                                                                   
 .ZVARS = '(ZENV ZCTY ZFLE ZKEY)'                                       
&PFKEY = ' '                                                           
)PROC                                                                   
 &PFKEY=.PFKEY                                                         
)END                                                                   


And you can exploit this using following rexx statements after making some modifications:

Code:

address ispexec"display panel(MYPANEL)"
do while pfkey ^= 'PF03'                 
. /* do ur validations etc... */
.
tbkey = '(rec)'                               
"ispexec tbcreate outdata keys "tbkey" nowrite"

do i = 2 to layout.0     /* layout will have ur file records...     */
   rec = strip(layout.i,'T',' ')             
   "ispexec tbadd outdata"                   
   "ispexec tbbottom" outdata                 
   end                                       
"ispexec tbtop" outdata                       
do forever                                   
   "ispexec tbdispl outdata panel(MYPANEL)" 
   lc = rc                                   
   if lc ^= 0 then leave
   end                                       
"ispexec tbend" outdata                       
rec = ''                                     
end                                           
.
.
.


So when you display the panel, you can simply do your PF7 PF8 etc until PF3...
Back to top
View user's profile Send private message
JOYEETA PAUL
Warnings : 1

New User


Joined: 18 Sep 2008
Posts: 16
Location: bangalore

PostPosted: Mon Sep 22, 2008 11:55 am    Post subject:
Reply with quote

actually my file is holding some pieces of code.if i select a certain condition the corresponding piece of code will be displaying in the panel.the code has more that one line.
here i think i can't use a table format. is there any other way to display the rec(code) in a panel? can anybody suggest me?
Back to top
View user's profile Send private message
dick scherrer

Global Moderator


Joined: 23 Nov 2006
Posts: 8604
Location: 221 B Baker St

PostPosted: Mon Sep 22, 2008 7:35 pm    Post subject:
Reply with quote

Hello,

Quote:
can anybody suggest me?
Not until we understand more clearly what you want to do. Keep in mind that your requirement is completely clear to you, but is not to others.

If may help if you can post a couple of examples of what you want to do/see on the panel. Use the Reply editor and the "Code" tg to prepare your samples. Use Preview to see how your post will appear to the forum (rather than how it appears in the reply editor). When you are satisfied with the appearance, Submit (do not forget to Submit or your work is gone icon_wink.gif ).
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF All times are GMT + 6 HoursGoto page 1, 2  Next
Page 1 of 2