The problem is with the way you did the readfile. You have:
"readfile ("pathname") htmlh."
You should have one of the following instead:
"readfile (pathname) htmlh." /* note that the (readfile) is inside the
quotes, not outside */
"readfile "pathname" htmlh." /* note lack of parentheses */
The manual is a bit confusing.
On Fri, Jan 31, 2014 at 7:02 AM, jan de decker <[email protected]> wrote:
> Hi list,
>
> I have a problem with a compiled simple rexx program (seee output below).
>
> I searched but could find no explanation for the rc(1) of the readfile
> command.
>
> The purpose is to implement this as a CGI program but for the moment it
> even fails the same way from the OMVS command line.
>
> The file
>
> /jedsp/web/pub/cgi/html_header
>
> exists and is a small text file containing a few lines of html headers.
>
> cat /jedsp/web/pub/cgi/html_header
>
> works fine.
>
> Any help would be greatly appreciated.
>
> Thx,
>
>
> j@n
>
>
>
> Hello
> 9 *-* if syscalls('ON')>3
> >L> "ON"
> >F> "0"
> >L> "3"
> >O> "0"
> 13 *-* pathname = '/jedsp/web/pub/cgi/html_header'
> >L> "/jedsp/web/pub/cgi/html_header"
> 14 *-* "readfile ("pathname") htmlh."
> >L> "readfile ("
> >V> "/jedsp/web/pub/cgi/html_header"
> >L> ") htmlh."
> >O> "readfile (/jedsp/web/pub/cgi/html_header"
> >O> "readfile (/jedsp/web/pub/cgi/html_header) htmlh."
> +++ RC(1) +++
> 15 *-* say rc
> >V> "1"
> 1
> 16 *-* say retval
> >L> "RETVAL"
> RETVAL
> 17 *-* do i = 1 to htmlh.0
> >L> "1"
> >L> "HTMLH.0"
> 17 +++ do i = 1 to htmlh.0
> EAGREX4100E Error 41 running compiled /jedsp/web/pub/cgi/sayhello,
> line 17: Bad arithmetic conversion
>
> ----------------------------------------------------------------------
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to [email protected] with the message: INFO IBM-MAIN
>
--
Wasn't there something about a PASCAL programmer knowing the value of
everything and the Wirth of nothing?
Maranatha! <><
John McKown
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN