Actually, the code for the spawning stuff is not written into my daemon project (which btw is now a C++ project). I wrote it into my main kixtart script which does a lot of other things and is probably way too convoluted if you're just getting started. But here is some specific help:1.) don't bother trying to pass the information to the clients from the run command.. start out by writing an environment variable with the information you want.
example:
shell @LDRIVE + "\bin\winset.exe pdc_server=qix"
Now you have the environment variable %pdc_server% which = "qix" on your client.
Next, spawn the process which sleeps for 5 minutes then executes a command..
$netlog = "@LDRIVE"
$script_name = "sleeper.kix"
run "$netlog\kix32.exe $netlog\$scriptname"
Okay now lets construct a simple sleeper.kix
sleep 300
; 5 minutes or (60 * 5) seconds
; now run your commands -- example:
shell "%comspec% /e:1024 /c biteme.exe /switch:%pdc_server%"
or
copy "\\%pdc_server%\sharename\myfile.ext" "c:\myfile.ext"
etc etc, you get the idea
Also, check out the kixtart manual kix95.doc, I find that it is generally very helpful.
(note: I didn't actually test these commands, so it wouldn't hurt to doublecheck me)
-Sven