Hi,
Wondered if somebody could kindly fix this up for me?
All I'm tryinng to do is push out a MSI using the PsExec tool remotley to other servers on the network.
I currently have it working as I need to in a batch file but need to convert this to a vbscript and my knowledge with vbscript isn't that great. It's a fairly long command line and this is just an example of one with all the parameters. When I try running the below though, all I seem to get is errors such as 'Expected end of statement' and Code 800A0401. I'm guessing it has something to do with the format of the string with quotes being in wrong places, not too sure.
Set wshshell = CreateObject("WScript.Shell")
Set runInstall = wshshell.Run"C:\psexec.exe \\BASSOL-PKGL-04 -u "username" -p "password" /accepteula /h /e msiexec /i "\\servername\share\myMSI.msi" AUTHENTICATION="NT" MASTER_SQL_INSTANCE="bassol-sqll-01\dev" PORT_CASMT="65001" MESSAGING_SERVER="localhost" MASTER_MAIN_DATABASE="qa2_2_17_Main" MYUSERNAME="svc" MYPASSWORD="Password1" /quiet",0,True
Thank you,
Paul
Wondered if somebody could kindly fix this up for me?
All I'm tryinng to do is push out a MSI using the PsExec tool remotley to other servers on the network.
I currently have it working as I need to in a batch file but need to convert this to a vbscript and my knowledge with vbscript isn't that great. It's a fairly long command line and this is just an example of one with all the parameters. When I try running the below though, all I seem to get is errors such as 'Expected end of statement' and Code 800A0401. I'm guessing it has something to do with the format of the string with quotes being in wrong places, not too sure.
Set wshshell = CreateObject("WScript.Shell")
Set runInstall = wshshell.Run"C:\psexec.exe \\BASSOL-PKGL-04 -u "username" -p "password" /accepteula /h /e msiexec /i "\\servername\share\myMSI.msi" AUTHENTICATION="NT" MASTER_SQL_INSTANCE="bassol-sqll-01\dev" PORT_CASMT="65001" MESSAGING_SERVER="localhost" MASTER_MAIN_DATABASE="qa2_2_17_Main" MYUSERNAME="svc" MYPASSWORD="Password1" /quiet",0,True
Thank you,
Paul