My customer's site has some ISPF applications installed. Most of the panels
support 'REFRESH' command to retrieve the newest data and present it to
user. They're wondering whether it is possible to develop an exec to
automatically issue REFRESH command every interval, say, 5 seconds. Just
like '&5' in SDSF.
Firstly I need to find a way to issue panel commands in REXX. The following
code works:
zcmd=zdel'refresh'zdel
/* REFRESH THE CURRENT PANEL */
"ISPEXEC VGET ZPANELID" /* GET THE CURRENT PANELID */
"ISPEXEC control nondispl end"
"ISPEXEC display panel("ZPANELID")"
return
However, if I add the wait logic and enclose them with a 'do forever' loop,
it doesn't work.
It seems to me that the panel will not be refreshed until the exec
terminates. The exec just dominates the screen. My design is:
user executes the exec in panel command line
|
exec refresh the panel to issue panel command
|
panel application executes the command and put the result to panel
|
exec gets control and start to wait some seconds
|
exec refresh the panel to issue panel command
and so on.....
Is it possible to do this in ISPF environment?
Thanks.
Best Regards,
Johnny Luo
Another issue with doing this sort of thing is how do they stop the auto refresh? IIRC, you have to trap the ATTN key. I don't know of another key that will "get through" while the terminal is in essence locked. If they use my suggestion above you could probably handle much easier. I use Tom Brennan's Vista TN3270 and it has buttons on the toolbar for starting and stopping a macro so it would be very easy to accomplish what your customer wants.
The control display lock causes the screen to display, but not unlock the keyboard.
Use attention to exit.
Also, a sample attention routine.
/* REXX */
signal on halt name attn;
zcmd=zdel'refresh'zdel
/* REFRESH THE CURRENT PANEL */
"ISPEXEC VGET ZPANELID" /* GET THE CURRENT PANELID */
do forever
"ISPEXEC control display lock"
"ISPEXEC display panel("ZPANELID")"
end
return
attn:
say "you hit the attention key at line" sigl"."
say sigl":" strip(sourceline(sigl),"l"," ")
if queued() <> 0 then "delstack"
exit 999
Dennis Roach
GHG Corporation
Lockheed Martin Mission Services
Facilities Design and Operations Contract Strategic Technical Engineering NASA/JSC
Address:
2100 Space Park Drive
LM-15-4BH
Houston, Texas 77058
Mail:
P.O. Box 58487
Mail Code H4C
Houston, Texas 77258-8487
Phone:
Voice: (281)336-5027
Cell: (713)591-1059
Fax: (281)336-5410
E-Mail: Dennis...@LMCo.COM
All opinions expressed by me are mine and may not agree with my employer or any person, company, or thing, living or dead, on or near this or any other planet, moon, asteroid, or other spatial object, natural or manufactured, since the beginning of time.
-----Original Message-----
From: ISPF discussion list [mailto:ISP...@LISTSERV.ND.EDU] On Behalf Of Johnny Luo
Sent: Friday, August 20, 2010 3:45 AM
To: ISP...@LISTSERV.ND.EDU