you can't mix the loop types like that
the goto nxt will never work as that loop has already exited
you dont need to fopen the file
Quote:

/test {
var %m = $lines(t.txt),%i = 1
while (%i <= %m) {
echo -s %i = $read(t.txt,%i)
inc %i
}
}


you should see an error msg if there is one for line too long anyway