[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index]
[Date Index]
[Thread Index]
[SQR-USERS Info]
[SQRUG Home Page]
Re: End-File
Gary,
The code you wrote, is it in a procedure that has
parameters? If so, you need to reference #_end-file
instead of #end-file.
Hope this helps.
Ray
> Hello,
>
> I am trying to process a text file and display it in an SQR report. As
> a test I created a three line text file e.g. :
>
> Line1
> Line22
> Line333
>
> I then wrote the following code to test I could iterate through the
> file:
>
> open 'c:\temp\test.txt' as 1 for-reading record=500:vary
> while 1
> read 1 into $temp:10
> if #end-file
> break
> end-if
> print $temp (+10, 10)
> end-while
> close 1
>
> This produces an infinite loop however. A few various test showed that
> #end-file was never set to 1 even when a string with an ascii value of 0
> was being read in.
>
> Has anyone any ideas?
> Apologies for a garbled last message. A slip of a mouse button.
>
> Thanks,
> Gary.
>
> ______________________________________________________
> Get Your Private, Free Email at http://www.hotmail.com
>
----------------------------------------------------------------------
Ray Ontko | Ray Ontko & Co | "Time for a new signature line."
rayo@ontko.com | Richmond, In | See us at http://www.ontko.com/
- References:
- End-File
- From: Gary Joynes <gary_joynes@HOTMAIL.COM>