What happens when you display that error message in the ELSE portion of your script ?

IF Open(1,"c:\templog.txt",2)= 0
?"@ERROR : @SERROR"
sleep 1
$result = ReadLine(1)
$x = SUBSTR("$result",20,15)
$ = Close(1)
ELSE
? "File not open"
?"@ERROR : @SERROR"
sleep 2
EndIf
? $x

-Shawn