Normale Version: Question about reading Data?
Du siehst gerade eine vereinfachte Darstellung unserer Inhalte. Normale Ansicht mit richtiger Formatierung.
It is a very simple question but I am unable to solve the problem. I have a data that holds these values:

inside a While AddItem I have a read dat, but it only is reading -1.

While AddItem(Objects())
   Restore MyValues
   Read dat(iCounter)
   NPrint dat(iCounter)
   If dat(iCounter)=-1 Then GoTo Skipping

Data -1,-1,-1,-1,16

When I run the program instead of getting -1,-1,-1,-1, 16...I am getting -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1.....all the way up to 59th -1. It is inside a loop that holds 59 items. I am Ok with the rest of them being -1...what I am not going that there is no 16 in the list. It is as if...and it is is as is reading only the first value from Data which is -1...then repeating that same first value 59 times.
Because you "restore" to MyValues within the loop.
Thanks Big Grin