I am having trouble reproducing this problem... This script segment appears to work in KiX 3.63 and KiX2k for me.Here is the dump when the file does not exist:
C:\scripts>k2 MCAlogin.kix
- 248-
- 249-
- 250-
- 251-
- 252-
- 253-
- 254-
- 255-
- 256-
- 257-
- 258-
- 259-
- 260-
- 270-
- 271-
KIX-LOGON 4.00 BETA 1
- 272-
- 273-
file c:\logon.lst
- 274-
file attributes <unknown>
- 275-
file size <unknown>
- 276-
- 277-
previous_logon_message <unknown>
- 278-
previous_workstation <unknown>
- 279-
- 280-
last_logon_message Last logon by 'cj' at wednesday 4-apr-2001 02:19:06
- 281-
last_workstation Location pc 'CJSCOMPUTER' of domain 'CJSDOMAIN'
- 282-
- 283-
- 286-
- 289-
and when the logon.lst file DOES exist:
C:\scripts>k2 MCAlogin.kix
- 248-
- 249-
- 250-
- 251-
- 252-
- 253-
- 254-
- 255-
- 256-
- 257-
- 258-
- 259-
- 260-
- 261-
- 262-
- 263-
- 266-
- 267-
- 268-
- 269-
- 270-
- 271-
KIX-LOGON 4.00 BETA 1
- 272-
- 273-
file c:\logon.lst
- 274-
file attributes 7
- 275-
file size 134
- 276-
- 277-
previous_logon_message Last logon by 'cj' at wednesday 4-apr-2001 02:19:06
- 278-
previous_workstation Location pc 'CJSCOMPUTER' of domain 'CJSDOMAIN'
- 279-
- 280-
last_logon_message Last logon by 'cj' at wednesday 4-apr-2001 02:20:34
- 281-
last_workstation Location pc 'CJSCOMPUTER' of domain 'CJSDOMAIN'
- 282-
- 283-
- 286-
- 289-
C:\scripts>
My additions to the code:
$user_drive="c:"
$debug_mode="yes"
My changes to the code:
?"- 252-" $last_logon_message="Last logon by '"+@fullname+"' at "+LCASE(@day)+" "+@mdayno+"-"+LCASE(substr(@month,1,3))+"-"+@year+" "+@time
?"- 253-" $last_workstation= "Location pc '"+UCASE(@wksta)+"' of domain '"+UCASE(@ldomain)+"'"
cj
------------------
For more scripts goto my website and click the hammer and spanner icon.
chrismat@ozemail.com.au