Dear,Our example which can give you an idea "how to do it" and with a message part.
Your temporary file can looks like:
f.e. script.ini
code:
[script]
comp1=x:\scripts\script1.kix
comp2=x:\scripts\script2.kix
comp3=x:\scripts\script1.kix
comp4=x:\scripts\script1.kix
comp5=x:\scripts\script5.kix
We are extending it to run different kind of scripts for different users.Your script can looks like:
code:
cls
$script_file="x:\scripts\script.ini"
$script_info=ReadProfileString($script_file,"script",@wksta)
IF (Len($script_info) <> 0)
IF (Exist($script_info) = 1)
CALL $script_info
IF (WriteProfileString($script_file,"script",@wksta,"") <> 0)
? "Warning KIX: problem with removing INI entry. error-code @error (@serror)."
ENDIF
ELSE
IF (MessageBox("Missing '+Ucase($script_info)+' file.'+CHR(10)+CHR(13)+'inform your helpdesk','Information message',0,5) <> 0)
ENDIF
ENDIF
ENDIF
greetings.btw: you can modify the MessageBox function to f.e. a WriteProfileString function.
Some like:
code:
IF (WriteProfileString($script_file,"script",@wksta,$script_info+" -missing file-") <> 0)
ENDIF
Also it is possible to use @userid as criteria instead of @wksta to
run a specified script.