Try this:

$rc = Open(1,"c:\templog.txt",2)
IF $rc = 0
? "file open"
$result = ReadLine(1)
$x = SUBSTR("$result",20,15)
? "substr = " + $x
$ = Close(1)
ELSE
? "File not open: Return code = " + $rc
? "Hit any key to continue"
Get $
EndIf


[ 09. July 2003, 19:56: Message edited by: Howard Bullock ]
_________________________
Home page: http://www.kixhelp.com/hb/