PASSING PARAMETER FROM ISPF TO REXX



IBM's Command List programming language & Restructured Extended Executor

PASSING PARAMETER FROM ISPF TO REXX

Postby mehi1353 » Mon Nov 19, 2012 4:07 pm

Hi,

I HAVE PROBLEM WITH PASSING PARAMETERS FROM MY ISPF PANEL TO A REXX PROGRAM.

FOR EXAMPLE, I WROTE A VERY SIMPLE PANEL TO READ A USERNAME AND SHOW IT A REXX PROGRAM.


MY PANEL CODE IS:

%COMMAND ===>_ZCMD                 
                                   
+USERID           ===>_UUSER   +   
                                   
)PROC                               
  VPUT (UUSER) SHARED
  &ZSEL = TRANS( TRUNC (&UUSER,'.')
  *, 'PGM(PASSSS)' )               
)END                     



AND THE RELEVANT REXX CODE(PASSSS) IS:

/* REXX */             
TRACE ON               
ADDRESS ISPEXEC         
"VGET (UUSER) SHARED"     
SAY 'THE USER IS:' UUSER


BUT IT DOESNT WORK AND always THE OUTPUT IS : ""THE USER IS: UUSER "" !!!

INSTEAD OF "SHARED",I TESTED "PROFILE".BUT THE RESULT WAS SAME.

COULD ANYBODY HELP?

BEST REGARDS,

MEHRDAD
mehi1353
 
Posts: 31
Joined: Sun Jan 11, 2009 4:51 pm
Has thanked: 0 time
Been thanked: 0 time

Re: PASSING PARAMETER FROM ISPF TO REXX

 

Re: PASSING PARAMETER FROM ISPF TO REXX

Postby enrico-sorichetti » Mon Nov 19, 2012 4:37 pm

for REXX dialogs theres is no need for the VPUT and VGET
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2706
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 139 times

Re: PASSING PARAMETER FROM ISPF TO REXX

Postby mehi1353 » Mon Nov 19, 2012 7:24 pm

Hi,

I tested without "VGET" in rexx program. but it still doesn't work.

do ia have to delete "VPUT" from my ispf panel ??


all the best
mehi1353
 
Posts: 31
Joined: Sun Jan 11, 2009 4:51 pm
Has thanked: 0 time
Been thanked: 0 time

Re: PASSING PARAMETER FROM ISPF TO REXX

Postby Pedro » Mon Nov 19, 2012 8:20 pm

The relationship between the panel and the rexx program is not clear. You should be displaying the panel from within the rexx program.
Pedro Vera
User avatar
Pedro
 
Posts: 579
Joined: Thu Jul 31, 2008 9:59 pm
Location: Silicon Valley
Has thanked: 0 time
Been thanked: 41 times

Re: PASSING PARAMETER FROM ISPF TO REXX

Postby NicC » Tue Nov 20, 2012 1:02 am

1) PLEASE DO NOT SHOUT
2) Please use the code tags when posting code. You have been around long enough to know this and to know how to use them. I have encoded your code for you.
3) Try looking at the source for one of your local menus as they, more often than not, invoke Rexx programs.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2755
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisies (almost)
Has thanked: 4 times
Been thanked: 110 times

Re: PASSING PARAMETER FROM ISPF TO REXX

Postby Pedro » Tue Nov 20, 2012 4:19 am

I cannot answer why it does not work. But frankly, I am surprised you got as far as you did.

From the ISPF Services manual, for SELECT PGM(somename):
This parameter must specify a name of a load module, load module
alias, or an entry point that is accessible by use of the LINK macro.

Since your rexx is none of those, I am surprised it got called at all.

I was not clear in my earlier post... you should invoke the rexx program first and from the rexx program you should use the DISPLAY service to invoke your panel (it should not have a zsel statement).

If, for some reason, you really insist to display the panel then call the rexx, you can pass your value as a parameter to the rexx.
Pedro Vera
User avatar
Pedro
 
Posts: 579
Joined: Thu Jul 31, 2008 9:59 pm
Location: Silicon Valley
Has thanked: 0 time
Been thanked: 41 times


Return to CLIST & REXX

 


  • Related topics
    Replies
    Views
    Last post