[23 May 2006] Creating a Table
Posted: Sat Jun 13, 2020 5:31 pm
Note: This is an archived post that was originally sent to the Hollywood mailing list on Tue, 23 May 2006 19:20:37 +0100
Well, I know this is probably yet another basic question, but I have to admit that I have some problems to understand how working with tables.
What I want to do is open a textfile and store every line into a table field. Here is my (none working) code sniplet:
Hollywood stops with an error, but I am not sure how to solve that, my guess is that I have to construct the counter another way. But how? Again, sorry for such basic things, but I went through that this the whole afternoon and it seems that I am somewhat blocked 
regards Oliver
Well, I know this is probably yet another basic question, but I have to admit that I have some problems to understand how working with tables.
What I want to do is open a textfile and store every line into a table field. Here is my (none working) code sniplet:
Code: Select all
test = {}
a = 0
OpenFile(1, "Games.txt", #MODE_READ)
While Not Eof(1) do test[a] = (ReadLine(1), a+1)
CloseFile(1)
regards Oliver