I'd change your select to shorter one.

something like:
code:
select
case @inwin = 2
$os=Win9x
$value = ReadValue("HKEY_LOCAL_MACHINE\software\Symantec\Norton Antivirus\", "currentversion")
$Tivolihome = ReadValue("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\RunServices\", "lcfd1")

case @inwin = 1 and @dos = "4.0"
$os=NT4
$NAVHome = ReadValue("HKEY_LOCAL_MACHINE\software\INTEL\LANDesk\VirusProtect6\CurrentVersion\", "Home Directory")
$value = GetFileVersion($NAVHome +"\vpc32.exe","ProductVersion")
$TivoliHome = ReadValue("HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\lcfd\", "run_dir")

case @inwin = 1 and @dos = "5.0"
$os="WIN 2000"
$NAVHome = ReadValue("HKEY_LOCAL_MACHINE\software\INTEL\LANDesk\VirusProtect6\CurrentVersion\", "Home Directory")
$value = GetFileVersion($NAVHome +"\vpc32.exe","ProductVersion")
$TivoliHome = ReadValue("HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\lcfd\", "run_dir")
endselect

$file=$Tivolihome+"\last.cfg"
$string="lcfd_version"
$found = 0

anyway, if it says illegal function... not quite sure what would do that.
you could change your if open to something like:
code:
if open(1,$file) ? "error opening file $file" get $nul
else
$line = readline(1)
...

this way it would show you also, what is the file it tries to open and so on...

-
_________________________
!

download KiXnet