From: MERC::"uunet!CRVAX.SRI.COM!RELAY-INFO-VAX" 10-JUN-1992 21:18:37.97 To: info-vax@kl.sri.com CC: Subj: Re: how do I do a run /detached and still give it argv[] arguments? In article <2JUN199219533934@nereid.sunquest.com>, spg@nereid.sunquest.com (Steve Gibbons) writes... wrote some stuff that attempted to help: #In article <1992Jun2.232443.20715@athena.mit.edu>, mlevin@forte.cs.tufts.edu writes... with his question about running foreign commands /detached and still managing to pass parameters to them That'll teach me to post in haste. The following should work a little bit better (It doesn't attempt to delete its undeletable PPFs) $ If F$Mode() .NeS. "OTHER" $ Then $ Scratch0 = F$Element(0, ";", F$Environment("Procedure")) + "_" + - F$GetJPI(0, "PID") $ Scratch1 = F$Element(0, ";", F$Environment("Procedure")) + "_OUT_" + - F$GetJPI(0, "PID") $ Open /Write Scratch0: 'Scratch0 $ Write Scratch0: "$ @''F$Environment(""Procedure"")'/Output=''Scratch1' ''P1' ''P2'" $ Write Scratch0: "$ Delete ''Scratch0';*,''Scratch1';*" $ Close Scratch0: $ Set Proc/Priv=Detach $ Run/Detach/Priv=All Sys$System:LoginOut /Input='Scratch0 - /Output=Nl: $ Exit $ EndIf $ On Error Then EOJ !We're detached, after all... $! (And it might be nice to look at the log file) $ com := "$dev:[dir]file.exe" $ com 'P1 'P2 Ugly hacks at midnight... -- Steve (SPG6) spg@sunquest.com