Old 28th October 2007, 18:19   #1
gregory.p.cliff
Junior Member
 
Join Date: Sep 2004
Location: Dardenne Prairie, MO
Posts: 8
Make a silent installer wait when called from a batch file

I created an NSIS installer that works great (Thank goodness for NSIS)! I would like to be able to run my installer from a Windows batch file with the silent option (/S) and have the batch file wait until the installer completes before proceeding on. My problem is that when I call the installer with the silent option (/S) it appears to go off on a separate thread and the batch file keeps on chugging.

Is there any easy way to fix this? Do I need to wrap one NSIS installer with another? I read quite a few threads on the use of execWait with a _? parameter as related to running uninstallers. Is that a or the solution.

Any guidance would be greatly appreciated. Thank you.
gregory.p.cliff is offline   Reply With Quote
Old 28th October 2007, 18:41   #2
CancerFace
Senior Member
 
Join Date: Apr 2006
Posts: 289
Send a message via ICQ to CancerFace
So, if you start your installer from within your windows batch file with
code:
start /wait 'installer.exe /S'
the batch file does not wait for the installer to finish?
CF
CancerFace is offline   Reply With Quote
Old 28th October 2007, 20:43   #3
Anders
Moderator
 
Anders's Avatar
 
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,216
I think the correct syntax would be:
start /wait installer.exe /S
or
start "" /wait "c:\some path\installer.exe" /S
if you need quotes (on NT)

IntOp $PostCount $PostCount + 1
Anders is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump