How to open exe file with parameters

Viewed 1452

I have batch file & vbs file that runs exe application in hidden mode. Now I would like to open this exe applicatio, but with parameters passed to it.

Batch file:

wscript.exe "C:\~some path~\invisible2.vbs" "C:\~some path~\Rserve_d.exe"

invisible2.vbs:

CreateObject("Wscript.Shell").Run """" & WScript.Arguments(0) & """", 0, False

Above code makes sure it runs hidden. But now I need to pass this parameter to the Rserve_d.exe when starting it:

--RS-conf "E:\~some path~\Rconf.cfg"

Please advise. I've tried with adjustments, but it seems, that there is always something wrong in the syntax.

2 Answers
Related