TIP: Click on subject to list as thread! ANSI
echo: power_bas
to: RONALD SCHLEGEL
from: WILLIAM JENIFER
date: 1997-05-29 20:14:00
subject: Read/data

-=> Quoting Ronald Schlegel to Sid Lee <=-
 
 RS> Tried that. Just one problem I encountered. It READs the same variable
 RS> over & over.
 RS> Ie:
 RS> 
 RS> READ Temp$
 RS> 
 RS> IF ERR =4 THEN
 RS> RESTORE
 RS> Read Temp$
 RS> END IF
 RS> 
 RS> It RESTOREs to the first DATA word & "refuses" to go past that. 
 RS> Ie:
 RS> 
 RS> DATA Run, Jog, Walk
 RS> 
 RS> If I execute the above READ statement 5 times, here is what will
 RS> return: 
 RS> Run
 RS> Jog
 RS> Walk
 RS> Run
 RS> Run
 RS> 
 RS> It never moves to the next one.
 
That is because ERR retains its value until a run-time error changes it or 
you change its value by assigning a value to it.  Try resetting ERR to zero
after the RESTORE command.
 
William Jenifer
 
BTW: Thanks for the comments on TMENU
 
... Send in competition answers with your name, age and how old you are.
--- TriBBS #573
---------------
* Origin: Sons Of Glitches BBS * 1-520-751-0229 * (1:300/114)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.