Reading Text File
- Posted by Steve Elder <SteveElde at AOL.COM> Jul 27, 1997
- 767 views
I'm trying to read a text file to the screen to the screen with this code. -----code starts here include get.e object file_num sequence line sequence buffer file_num = open("d:\\fuphoria\\eudata\\hockey.txt", "r") -- read a text file into a sequence buffer = {} while 1 do line = gets(file_num) if atom(line) then exit -- end of file end if buffer = append(buffer, line) end while puts(1,buffer) -- this produces ex.err: --D:\EUPHORIA\EUDATA\CASEDATA\CASE2.EX:13 --file_num has not been declared -- file_num = open("case.dat", "u") Really strange since file_num HAS been declared. Steve Elder