Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Using *REXX in Panel

536 views
Skip to first unread message

Lizette Koehler

unread,
Sep 15, 2011, 10:17:46 AM9/15/11
to
I am working on understanding how the *REXX works in a Panel. I have been
reading the Dialogue Manual but it is not much help. ;-)

I have a simple process, display a list of selections in the panel, then
call a rexx to count the vars, then produce the number of selection.

)ATTR DEFAULT(%+_)

% TYPE(TEXT) INTENS(HIGH)

~ TYPE(TEXT) INTENS(LOW) COLOR(TURQ)

} TYPE(TEXT) INTENS(LOW) COLOR(BLUE)

` TYPE(INPUT) INTENS(HIGH) COLOR(WHITE) PADC('_')

! TYPE(TEXT) INTENS(HIGH) COLOR(WHITE)

)BODY EXPAND(##)

# #Request Processing# #
+COMMAND ===>`ZCMD

+

Select: (Use~S+or!Y+)



`z+ VAR1

`z+ VAR1 Mailbox



`z+ VAR2


`z+ VAR3


`z+ VAR4


`z+ VAR5






)INIT
.HELP = HOPM0001 /* insert name of tutorial panel */
.ZVARS = '(VAR1 VAR1CALV VAR2 VAR3 VAR4 VAR5 ) '
&CALV = 0
)PROC
IF (.RESP = END)
&RSP = END
IF (.RESP = ENTER)
&RSP = ENTER
IF (.RESP = RETURN)
&RSP = RETURN
If (Ver(&r,nb))
&r = 'Y'
if (ver(&VAR1,nb))
*REXX(*,CALV,(CALVARS))
if (ver(&VAR1CALV,nb))

*REXX(*,CALV,(CALVARS))
If (ver(&VAR2,nb))
*REXX(*,CALV,(CALVARS))
If (ver(&VAR3,nb))
*REXX(*,CALV,(CALVARS))
If (ver(&VAR4,nb))
*REXX(*,CALV,(CALVARS))
If (ver(&VAR5,nb))
*REXX(*,CALV,(CALVARS))
)END


CALVARS Code:

/* Rexx -
Calculate the number of variables
*/

Say CALV
CALV = CALV + 1
Say CALV

Exit

Simple enough, but I am not getting the results I want. A trace shows that
my CALV var is getting reset to 0 each time - CALV is always one even though
multiple selections. Each call to the CALVARS routing has the CALV var as
blank. And even if it gets the first execution correct - it goes back to
blanks on the next call.


So, how can I set this up to do a tally. Do I need to keep the rexx all in
the panel or is there something I am missing in this process.

Thanks

Lizette

Styles, Andy , TME - Service Support

unread,
Sep 15, 2011, 10:25:13 AM9/15/11
to
In some code I've got, I have a call at the start and end:


Call ISPPRXVP 'I'

If AuthUser('NDVRADMN') Then
ADMIN = 'Y'
Else
ADMIN = 'N'

Call ISPPRXVP 'T'

As per:

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ISPZDG60/7.2.7.1?SHELF=ISPZPM61&DT=20070621205851&CASE=

--
Andy Styles
Lloyds TSB Bank plc. Registered Office: 25 Gresham Street, London EC2V 7HN. Registered in England and Wales, number 2065. Telephone: 020 7626 1500.
Bank of Scotland plc. Registered Office: The Mound, Edinburgh EH1 1YZ. Registered in Scotland, number 327000. Telephone: 0870 600 5000

Lloyds TSB Scotland plc. Registered Office: Henry Duncan House, 120 George Street, Edinburgh EH2 4LH. Registered in Scotland, number 95237. Telephone: 0131 225 4555.
Cheltenham & Gloucester plc. Registered Office: Barnett Way, Gloucester GL4 3RL. Registered in England and Wales, number 2299428. Telephone: 01452 372372.

Lloyds TSB Bank plc, Lloyds TSB Scotland plc, Bank of Scotland plc and Cheltenham & Gloucester plc are authorised and regulated by the Financial Services Authority.
Halifax is a division of Bank of Scotland plc. Cheltenham & Gloucester Savings is a division of Lloyds TSB Bank plc.

HBOS plc. Registered Office: The Mound, Edinburgh EH1 1YZ. Registered in Scotland, number 218813. Telephone: 0870 600 5000

Lloyds Banking Group plc. Registered Office: The Mound, Edinburgh EH1 1YZ. Registered in Scotland, number 95000. Telephone: 0131 225 4555

This e-mail (including any attachments) is private and confidential and may contain privileged material. If you have received this e-mail in error, please notify the sender and delete it (including any attachments) immediately. You must not copy, distribute, disclose or use any of the information in it or any attachments.

Telephone calls may be monitored or recorded.


______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email
______________________________________________________________________

Styles, Andy , TME - Service Support

unread,
Sep 15, 2011, 10:45:40 AM9/15/11
to
Actually, having re-read that part of the manual, it appears that I don't need those calls, as this is interpreted REXX..

Ho hum.

Andy Styles

-----Original Message-----
From: Styles, Andy (TME - Service Support)
Sent: 15 September 2011 15:25
To: ISP...@LISTSERV.ND.EDU
Subject: RE: Using *REXX in Panel

In some code I've got, I have a call at the start and end:


Call ISPPRXVP 'I'

If AuthUser('NDVRADMN') Then
ADMIN = 'Y'
Else
ADMIN = 'N'

Call ISPPRXVP 'T'

As per:

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ISPZDG60/7.2.7.1?SHELF=ISPZPM61&DT=20070621205851&CASE=

--
Andy Styles


-----Original Message-----
From: ISPF discussion list [mailto:ISP...@LISTSERV.ND.EDU] On Behalf Of Lizette Koehler
Sent: 15 September 2011 15:17
To: ISP...@LISTSERV.ND.EDU
Subject: Using *REXX in Panel

Styles, Andy , TME - Service Support

unread,
Sep 15, 2011, 10:56:42 AM9/15/11
to
Cracked it!

Take the EXIT statement out of the REXX.

From the manual:

___ Interpreted panel REXX and the EXIT statement ______________________
| |
| If the interpreted panel REXX code uses the EXIT statement to |
| terminate REXX processing, the termination call to ISPPRXVP generated |
| by ISPF will not be executed. Therefore, any changes made to REXX |
| variables will not be applied to the corresponding ISPF dialog |
| variables. If you need to use the EXIT statement in your panel REXX |
| and you want changes applied to the ISPF dialog variables, ensure a |
| termination call to ISPPRXVP (that is, Call ISPPRXVP 'T') is run |
| before the EXIT statement. |
| |
|________________________________________________________________________|


Andy Styles

-----Original Message-----
From: ISPF discussion list [mailto:ISP...@LISTSERV.ND.EDU] On Behalf Of Lizette Koehler
Sent: 15 September 2011 15:17
To: ISP...@LISTSERV.ND.EDU
Subject: Using *REXX in Panel

Lizette Koehler

unread,
Sep 15, 2011, 11:56:20 AM9/15/11
to
I guess skimming the section was at too high and overview. I missed the
Mountain.

Thanks

Lizette

> -----Original Message-----
> From: ISPF discussion list [mailto:ISP...@LISTSERV.ND.EDU] On Behalf Of
Styles,
> Andy (TME - Service Support)

Steve Coalbran

unread,
Sep 16, 2011, 1:45:36 AM9/16/11
to
Hi Lizette - see the post I did to Thomas Berg recently "RE: Problems with dynamic attributes in DYNAMIC area ?".
this has a couple of sample *REXX procs that may be of use as examples ?
(I can resend privately if you already dumped it?)
;-) /S

> Date: Thu, 15 Sep 2011 11:53:07 -0400
> From: star...@MINDSPRING.COM
> Subject: Re: Using *REXX in Panel
> To: ISP...@LISTSERV.ND.EDU

adrianstern

unread,
Sep 16, 2011, 4:13:12 AM9/16/11
to
It still amazes me that you all still put code in the panels rather
than doing it all in a rexx driver. Allocating help panels and other
strictly panel related commands must be there but they are very few -
and life is SO much easier with all handling in one place. If examples
are needed I'll gladly supply some.
0 new messages