OK, here is the code you asked for.
The logon script is test.bat this file contains:
code:
  
%0\..\Kix32 test.kix

The test.kix script contains:
code:
  
$key = existkey("HKEY_CURRENT_USER\software\company")
IF $key <> 0 $temp=addkey("HKEY_CURRENT_USER\software\company")
ENDIF
$image = Readvalue ("HKEY_CURRENT_USER\software\company", "software")
IF $image < "1"
; some commands that are completed successful;
$temp=delprogramitem ("CdFoongids")
$temp=addprogramitem ("Q:\WIN32\KPNWIN.EXE","CDFoongids","",0,"Q:\WIN32",0,0)
$temp=addprogramitem ("\\Server1\travel\Travman.exe","Travelmanager","",0,"\\license\travel",0,0)
$temp=addprogramitem ("F:\APPS\Euroglot\EUROGLOT.EXE","Euroglot","",0,"F:\APPS\Euroglot",0,0)
$Temp=Writevalue("HKEY_CURRENT_USER\software\company","software","1","REG_SZ")
ENDIF
; End of script;

When logging on, all looks OK, even the value of sofware in the registry is changed to 1, but nothing happens in the program folder.
When changing this value back and starting the script manually it works fine.