How to find the eof in REXX?

Time Sharing Option, Interactive System Productivity Facility and REstructured eXtended eXecutor

Moderator: mickeydusaor

Post Reply
Ashish Jain
New Member
Posts: 6
Joined: Tue Jun 17, 2014 4:54 pm

How to find the eof in REXX?

Post by Ashish Jain »

Hi,

Please can anyone let me know in REXX while reading a file into stack how can I come to know that the file is at end? Is there some line of codes I've to write for it?

Thanks!
enrico-sorichetti
Global Moderator
Global Moderator
Posts: 826
Joined: Wed Sep 11, 2013 3:57 pm

Re: How to find the eof in REXX?

Post by enrico-sorichetti »

check the return code after the EXECIO
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 8-)
Ashish Jain
New Member
Posts: 6
Joined: Tue Jun 17, 2014 4:54 pm

Re: How to find the eof in REXX?

Post by Ashish Jain »

And if it's 0 (zero) it's the EOF? Please guide.
enrico-sorichetti
Global Moderator
Global Moderator
Posts: 826
Joined: Wed Sep 11, 2013 3:57 pm

Re: How to find the eof in REXX?

Post by enrico-sorichetti »

why not run a couple of simple tests Yourself ?
( displaying the return code after the EXECIO )

or/and look at the manuals starting from
http://www-03.ibm.com/systems/z/os/zos/ ... index.html
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 8-)
thiele3105
New Member
Posts: 7
Joined: Mon Jan 26, 2015 7:49 pm

Re: How to find the eof in REXX?

Post by thiele3105 »

If you make execio * diskr file ( stem a. then the number of lines are in a.0.
Otherwise you read line per line with execio 1 diskr file
then the rc > 0 when eof.

best regards
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “TSO, ISPF & REXX (Do you still do CLIST?!).”