View previous topic :: View next topic |
Author |
Message |
Protected Valued Contributor
Joined: 02 Jan 2001 Posts: 228 Location: Portugal
|
Posted: Fri Feb 15, 2002 1:18 am Post subject: Help me.. urgent... Simple code |
|
|
LIST LOADFILE,HIDDEN,%%PathDir\DATA\RANDBAT.DAT
%%AA = -1
repeat
%%AA = @succ(%%AA)
LIST SEEK,HIDDEN,%%AA
LIST PUT,HIDDEN,0
until @equal(@index(HIDDEN),@pred(@count(HIDDEN)))
LIST SAVEFILE,HIDDEN,%%PathDir\DATA\RANDBAT.DAT
What the hell is wrong with this? Assumming that THERE is a "HIDDEN" list, there is a RANDBAT.DAT (and it's not empty)? This is making a list index out of range error |
|
Back to top |
|
|
SnarlingSheep Professional Member
Joined: 13 Mar 2001 Posts: 759 Location: Michigan
|
Posted: Fri Feb 15, 2002 2:09 am Post subject: |
|
|
You might want to try it like this:
Code: |
LIST LOADFILE,HIDDEN,%%PathDir\Data\RANDBAT.DAT
%%AA = 0
repeat
LIST SEEK,HIDDEN,%%AA
LIST PUT,HIDDEN,0
%%AA = @succ(%%AA)
until @equal(%%AA,@count(HIDDEN))
LIST SAVEFILE,HIDDEN,%%PathDir\Data\RANDBAT.DAT
|
_________________ -Sheep
My pockets hurt... |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You can attach files in this forum You can download files in this forum
|
|