View previous topic :: View next topic
|
Author |
Message |
amitava Warnings : 1 Active User
Joined: 30 Oct 2005 Posts: 186 Location: India
|
|
|
|
Hi All,
I want to prepare a ISPF panel by REXX and I am able to make it. The sample code is just like below -
Code: |
)ATTR
# TYPE(AB)
? TYPE(TEXT) INTENS(HIGH) JUST(LEFT) COLOR(YELLOW)
_ TYPE(INPUT) INTENS(HIGH) CAPS(ON) COLOR(BLUE) HILITE(USCORE)
! COLOR(RED) INTENS(HIGH) TYPE(TEXT)
@ COLOR(BLUE) INTENS(HIGH) TYPE(TEXT)
)ABC DESC ('Menu') MNEM(1)
PDC DESC('Checkit') ACC(Alt+F1)
ACTION RUN(checkit)
PDC DESC('CoolDown') ACC(Alt+F2)
ACTION RUN(cooldwn)
)ABCINIT
.zvars = PDCHOICE
&PDCHOICE = ''
)ABCPROC
ver(&PDCHOICE,LIST,1,2)
)BODY
+?
# Menu
%COMMAND ===>_ZCMD +
)init
)reinit
)proc
)END
|
But with this, I am not being able to go out of this panel. Whenever I am pressing pF3, the panel remains there and no exit is performed. It seems it has entered into an endless loop. Sample code in REXX is -
Code: |
do forever
"display panel(P#MAIN)"
say rc zerrlm
if(rc =8) then leave
if(rc = 0) then call process_data
end
|
Previously with an ISPF panel with no action bar option, it worked fine. But it is not working with the panel having action bar. Please help me out of this situation. I am not being able to diagnose the problem. |
|
Back to top |
|
|
Marso
REXX Moderator
Joined: 13 Mar 2006 Posts: 1353 Location: Israel
|
|
|
|
Amitava,
I copied the panel code on my site but got an error:
"Field or area name missing following identifying attribute character."
Can you recheck your code ? |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
Code: |
do forever
"display panel(P#MAIN)"
say rc zerrlm <=== REMOVE THIS LINE
if(rc =8) then leave
if(rc = 0) then call process_data
end
|
Remove the "say" command. After it executes, the value for rc will be zero. |
|
Back to top |
|
|
amitava Warnings : 1 Active User
Joined: 30 Oct 2005 Posts: 186 Location: India
|
|
|
|
Hi Marso,
I don't think it is having some problem in code. May be while copying, you have copied it into a dataset/member of a PDS whose profile has not been set to NUM OFF.
I am telling this because the code is running in my site.
Regards,
Amitava |
|
Back to top |
|
|
amitava Warnings : 1 Active User
Joined: 30 Oct 2005 Posts: 186 Location: India
|
|
|
|
Hi Superk,
I have removed the SAY command and also tried to run the code. But it is giving the same response.
I think, I am not very clear about my problem. OK; Let me specify it thoroughly.
With the code mentioned above, if I execute the REXX routine then it will open the panel. In this panel, without doing anything, if you press pF3, it will not work. But if you select any action bar choice and then press pF3, it will work, close the panel and terminate the REXX routine.
Am I clear about specifying my query? Please help me out. |
|
Back to top |
|
|
Marso
REXX Moderator
Joined: 13 Mar 2006 Posts: 1353 Location: Israel
|
|
|
|
After I corrected the COPY/PASTE problem, I got the same results as you did.
What's strange is that option 7.2 (Display panel) behaves the same: PF3 just does nothing.
Also, you don't have to use the action bar to make it work:
just type something in the command line then hit PF3.
Among other tests, I decided to add a field to the empty panel.
Guess what? it started to work.
Try that too and tell us if it fixed the problem. |
|
Back to top |
|
|
UmeySan
Active Member
Joined: 22 Aug 2006 Posts: 771 Location: Germany
|
|
|
|
Hi amitava !
You could also do it this way:
ADDRESS ISPEXEC "ADDPOP"
ADDRESS ISPEXEC "DISPLAY PANEL(UMIPUFER)"
IF RC > 0 THEN DO
RETURN
END
Regards, UmeySan |
|
Back to top |
|
|
amitava Warnings : 1 Active User
Joined: 30 Oct 2005 Posts: 186 Location: India
|
|
|
|
Hi Marso,
Really good work. Your effort to analyze the problem is quite appreciable. Yop, without any statement in )BODY section, it is not working properly-I mean pF3 will not work. But if you add even a single protected field in )BODY section, pF3 key will start working.
Sorry Marso, I don't know the reason- why are we gettin such kind of behaviour. I will look for it but request to all other members, if they know the reason then please help us out by clarifying the fact.
Regards,
Amitava |
|
Back to top |
|
|
|