Use SPACE COMMA at the end of each separate line of arguments except the last line with the closing parenthesis.
Comma at the end of a Rexx line says concatenate the next line with the current line, so your ARGUMENT comma is taken as a CONTIUATION comma. Adding SPACE COMMA after the ARGUMENT comma on each continuing line will solve your problem. HTH Peter -----Original Message----- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Jantje. Sent: Friday, April 6, 2018 11:19 AM To: IBM-MAIN@LISTSERV.UA.EDU 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,SYSTYPE,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,SYSTYPE,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. -- This message and any attachments are intended only for the use of the addressee and may contain information that is privileged and confidential. If the reader of the message is not the intended recipient or an authorized representative of the intended recipient, you are hereby notified that any dissemination of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by e-mail and delete the message and any attachments from your system. ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN