View Full Version : How to run 2 .exe files same time?
4th March 2009, 22:41
I want is to create an NSIS script to run 2 exe files both same time.
I want to run the both exe files silent (SilentInstall silent) and to add an icon to it. The location of the files should be "EXEDIR".
The first exe run other process then exit so the ExecWait seems not help this case. Also don't need ExeTimeout because don't want any exe process closed after some time.
Thank you for any help.
4th March 2009, 23:09
You should be able to just use the Exec command.
Running them silent might be an issue depending how the EXE you want to run is configured. (If it was built with NSIS, then you have some amount of control; otherwise, you're stuck with whatever the developer gave you.)
If you are running console apps, you can use the ExecCmd (http://nsis.sourceforge.net/ExecCmd_plug-in) or ExecDos (http://nsis.sourceforge.net/ExecDos_plug-in) plugin with the asynchronous option set.
5th March 2009, 00:16
I just created the next script and seems that run ok but don't know if will work also with Vista (I use XP). Please confirm if this is the right way and all is in order:
SetCompressor /SOLID LZMA
5th March 2009, 14:30
I'm not sure just nsExec will work to run simultaneously (which is what you originally asked, correct?)
And there's nothing unique about actually running an app under Vista. Where you might have problems there is with folder and registry re-direction and permission issues (both usually a direct result of UAC.)
If you're looking for Vista-related problems/solutions, just search the forum for 'Vista' and you'll see quite a bit of info.
6th March 2009, 13:13
The script below run fine on Windows XP and also on Vista (tested with Vista Business) but when I try it on Vista Business installed on an HTC Shift which is only 800 MHz processor with 1GB RAM, I found that there is a problem because only one process running and the second remain residen on memory or not run.
I think that I should find a way to add a pause in order to have the second EXE running at few seconds after the first one was started.
I think that ExeTimeout will kill the started process when the time expired and ExeWait will wait for the EXE to end before run the second EXE but the EXE's need to stay active so that's why I preffered Exec but nobody confirm me if is the best option or if there is any other recommended method. If you have this please just let me know an example.
This is the script I use now:
SetCompressor /SOLID LZMA
vBulletin® v3.8.6, Copyright ©2000-2013, Jelsoft Enterprises Ltd.