TIP: Click on subject to list as thread! ANSI
echo: os2prog
to: Joey Snell
from: Ed Blackman
date: 1994-06-14 12:55:38
subject: REXX headaches, C++ Dreams!

On  in a message to All, Joey Snell wrote:

JS> for each individual file.  The .CFG file aproach is much more
JS> professional but I am having a helluva hard time getting REXX to
JS> interpret the file and disregard the commented-out lines that it
JS> should contain.  REXX apparently has no EOLN() or EOF()
JS> functions so it is very hard to control the reading of the file.

Check out the LINEIN() and LINES() functions in the online REXX
reference.  Something like this is what you need:

/* warning: untested code */

CFGFile = "MyFile.CFG"
do while LINES(CFGFile) = 1
    line = LINEIN(CFGFile)
    /* do all your line processing here, or perhaps store the lines */
    /* in a stem variable for later processing */
end


Ed Blackman

... I wrote in COBOL once, but I didn't compile.
--- Blue Wave/Max v2.12 [NR]

* Origin: The Federal Post -{*}- Spring-Lake, NC (1:3634/2)
SEEN-BY: 54/54 620/243 632/348 640/820 690/660 711/409 413 430 807 808 809
SEEN-BY: 711/934 712/353 623 713/888 800/1 2442/0
@PATH: 3634/2 1 3615/50 229/2 2442/0 711/409 54/54 711/808 809 934

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.