File Open External, Ouput
Posted: Wed Nov 18, 2009 10:59 am
BR Versions 4.18j, 4.17o and I would suspect 4.2 has the same behaviour.
Open External - EOL=CRLF syntax allowed, but doesn't work.
Open #110: "NAME=File.dat,REPLACE,RECL=132,EOL=CRLF",External,Output
The BR Manual - does not list this Eol=CRLF parameter as being an option for opening External files, but this syntax is allowed.
To make it work, we added:
Let BL$=RPT$(" ",132) : Let BLK$=RPT$(" ",130)&CHR$(13)&CHR$(10) - added the Chr$(13)&Chr$(10) to the end of each record manually.
Suggestion:
1. Either make the EOL=CRLF work with External Files, and put in the CRLF automatically
or
2. Generate a syntax error when coding the Open statement.
This is deceiving and frustrating when testing new code.
Open External - EOL=CRLF syntax allowed, but doesn't work.
Open #110: "NAME=File.dat,REPLACE,RECL=132,EOL=CRLF",External,Output
The BR Manual - does not list this Eol=CRLF parameter as being an option for opening External files, but this syntax is allowed.
To make it work, we added:
Let BL$=RPT$(" ",132) : Let BLK$=RPT$(" ",130)&CHR$(13)&CHR$(10) - added the Chr$(13)&Chr$(10) to the end of each record manually.
Suggestion:
1. Either make the EOL=CRLF work with External Files, and put in the CRLF automatically
or
2. Generate a syntax error when coding the Open statement.
This is deceiving and frustrating when testing new code.