Old 1st June 2007, 11:05   #1
graz79
Junior Member
 
Join Date: Jun 2007
Posts: 2
nsis Exec: failed createprocess

My installer ships a vbs install script to create the SQL database and IIS website. Run manually the vbs file completes.
Within my NSI script i have the following
Quote:
Section CreateDB
detailprint "Creating SQL database on $DBNAME"
ExecWait '"$INSTDIR\install\install.vbs" "$DBNAME" "$DBLOGIN" "$DBPASSWORD" "$APPNAME" "$WEBIP"'
IfErrors +1 +2
LogText 'Error running "$INSTDIR\install\install.vbs" "$DBNAME" "$DBLOGIN" "$DBPASSWORD" "$APPNAME" "$WEBIP"'
SectionEnd
Using the NSIS installer i get the following error in the logs

Quote:
Exec: failed createprocess
for this command.

I need this script to execute before the installer exits. Can anyone shed any light or recommend and alternative?

Thanks
Graz
graz79 is offline   Reply With Quote
Old 1st June 2007, 11:30   #2
Takhir
Major Dude
 
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
Exec starts executable, not script, shell required to run vbs. And Forum Search is you best friend
http://forums.winamp.com/showthread....&highlight=vbs
If this opens black console window, you can take vbs extension handler from Registry (what ExecShell does) and run it using nsExec (included to distribution) or ExecDos plug-in (from Dev. center).
Takhir is offline   Reply With Quote
Old 1st June 2007, 12:06   #3
graz79
Junior Member
 
Join Date: Jun 2007
Posts: 2
Thanks a lot

But i know get this

ExecShell: warning: error ("OPEN": file:""C:\Program Files\TrustNET\install\install.vbs" "Melbourne" "sa" "surfsup" "TrustNET" "192.168.1.200" "C:\Program Files\TrustNET"" params:"SW_SHOWNORMAL")=2

My script returns 100 not 2 on an error i.e. WScript.Quit(100)
graz79 is offline   Reply With Quote
Old 1st June 2007, 23:09   #4
demiller9
Senior Member
 
Join Date: Mar 2006
Location: Dallas
Posts: 462
Use Exec (or NsExec::Exec) with "Wscript.exe $PROGRAMFILES\TrustNET\install\install.vbs Melbourne sa surfsup TrustNET 192.168.1.200 $PROGRAMFILES\TrustNET"
demiller9 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