Personally in REXX I use a list with SPACE between each arg and a blank comma 
at the end

VAR =' a b c ' ,
     ' d e f '

Next, if you did not know, there is a TSO/REXX group can you also post these 
kinds of questions to

To join, if you have not done so,

TSO REXX        http://www2.marist.edu/htbin/wlvindex?TSO-REXX

This one you have to go to the bottom of the webpage.

Lizette


> -----Original Message-----
> From: IBM Mainframe Discussion List <[email protected]> On Behalf Of
> Jantje.
> Sent: Friday, April 06, 2018 8:19 AM
> To: [email protected]
> Subject: Many arguments to a Rexx function call
> 
> Dear Listers,
> 
> How can I make this:
> 
> RS=ALERTSN(SEV,TYPENAME,ELEMENT,DESC,STATUS,STSDESC,
>   SUBSRC,SOURCE,LOCATION,SYSTYPE,PLTFTYPE,IMPACT,HOST,
>   MONENV,RESOURCE,EXTRINFO,ACTIVE,CLOSING,FTPERR,
>   APPLTYPE,APPLNAME,UNIQUE)
> 
> actually work?
> 
> What happens is that the values of STSDESC and SUBSRC get concatenated and
> then the rest of the argument list is shifted up one place. Same with HOST
> and MONENV. FTPERR, APPLTYPE, PPLNAME and UNIQUE don't get a value assigned
> in the called function, because by then, the arguments have been shifted too
> much and there are none left to give them any value.
> 
> I know that are a lot of arguments, but I cannot for the life of me find a
> book that states there is a limitation to the number of arguments in a
> function call. The problem is definitely with the continuation of the
> statement over several lines. I have searched both User Guide and Reference
> Manual and both seem to indicate one has to put a comma at the end of the
> line that is to be continued. But when I do that:
> 
> RS=ALERTSN(SEV,TYPENAME,ELEMENT,DESC,STATUS,STSDESC,,
>   SUBSRC,SOURCE,LOCATION,SYSTYPE,PLTFTYPE,IMPACT,HOST,,
>   MONENV,RESOURCE,EXTRINFO,ACTIVE,CLOSING,FTPERR,,
>   APPLTYPE,APPLNAME,UNIQUE)
> 
> I get:
> 
>     55 +++
> RS=ALERTSN(SEV,TYPENAME,ELEMENT,DESC,STATUS,STSDESC,,SUBSRC,SOURCE,LOCATION,S
> YSTYPE,PLTFTYPE,IMPACT,HOST,,MONENV,RESOURC
> E,EXTRINFO,ACTIVE,CLOSING,FTPERR,,APPLTYPE,APPLNAME,UNIQUE)
> IRX0040I Error running ALERTSNB, line 55: Incorrect call to routine
> 
> Then I thought to get clever and I built one long string containing the
> entire call in one line and executed that by using INTERPRET:
> 
> LongInstr='RS=(ALERTSN SEV,TYPENAME,ELEMENT,DESC,STATUS,STSDESC,'!!,
> 'SUBSRC,SOURCE,LOCATION,SYSTYPE,PLTFTYPE,IMPACT,HOST,'!!,
> 'MONENV,RESOURCE,EXTRINFO,ACTIVE,CLOSING,FTPERR,'!!,
> 'APPLTYPE,APPLNAME,UNIQUE')
> interpret LongInstr
> 
> No such luck :-(
> 
>     59 +++
> RS=ALERTSN(SEV,TYPENAME,ELEMENT,DESC,STATUS,STSDESC,SUBSRC,SOURCE,LOCATION,SY
> STYPE,PLTFTYPE,IMPACT,HOST,MONENV,RESOURCE
> ,EXTRINFO,ACTIVE,CLOSING,FTPERR,APPLTYPE,APPLNAME,UNIQUE)
>     59 +++ interpret LongInstr
> IRX0040I Error running ALERTSNB, line 59: Incorrect call to routine
> 
> It's Friday afternoon and I have a headache...
> 
> To all you Rexx experts, please, how does one go about passing many arguments
> to a function?
> 
> Thanks and very best regards,
> 
> Jantje.

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to