I am running a vbscript through msi using the Action: Execute commandline from path.where property is set as [WindowsFolder]system32\cscript.exe and vbs file in commandline.(that vbfile is present in the machine where package is goin to install).But problem is with silent installation.On installing package ,the cmd window will pop up and go.Can any one suggest a method to hide this cmd window popping up during package installtion?
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

Answers

0
Use 'START /B CSCRIPT [blah, blah, blah...]'.

Make sure that your script has thorough logging since, with no command window, it will be impossible to track failures.
Answered 03/07/2011 by: VBScab
Red Belt

Please log in to comment
0
did you try with wscript.exe ?
Answered 03/07/2011 by: mekaywe
Brown Belt

Please log in to comment
0
Thanks for the reply.
Let me try with Start /B...
But I am not allowed to use wscript in this case.
Answered 03/07/2011 by: Anjana
Senior Yellow Belt

Please log in to comment
0
But Start /B is giving error in MSI. :-(
Answered 03/10/2011 by: Anjana
Senior Yellow Belt

Please log in to comment
0
We can see "the error" from here, of course...
Answered 03/10/2011 by: VBScab
Red Belt

Please log in to comment
0
ORIGINAL: Anjana

I am running a vbscript through msi using the Action: Execute commandline from path.where property is set as [WindowsFolder]system32\cscript.exe and vbs file in commandline.(that vbfile is present in the machine where package is goin to install).But problem is with silent installation.On installing package ,the cmd window will pop up and go.Can any one suggest a method to hide this cmd window popping up during package installtion?


If the VBS file is consistent across all machines to which you plan to deploy the package, why not import the contents of the script and construct a Type 6 or type 38 custom action ? That way you eliminate the need for cscript.exe and the command window. There are a few caveats to this depending on the contents of your script, for example any code which uses the WScript object (e.g. wscript.sleep) will not work in a custom action.

Alternatively You might want to try out the method using wixca.dll, which I posted here

Spartacus
Answered 03/17/2011 by: spartacus
Black Belt

Please log in to comment
0
I suggest revising the script to work in WScript instead of CScript, since CScript is specifically intended to run in a console window (hence its name).
Answered 03/17/2011 by: mazessj
Blue Belt

Please log in to comment
0

When editing a script, you can click the "View raw XML editor" link under the Scheduling section. If you change the type=policy field to type=hidden, the entire script will run in silent mode.

<config name="Blah Blah script that does whatever" type="hidden" id="106" version="1393522756" description="Whatever this script does.">

If you need to export the script as a resource to another Org on the KACE appliance, you will have to change it back from hidden to policy as it will not show up in the list of available resources.

Answered 02/27/2014 by: angrymidget
White Belt

Please log in to comment
Answer this question or Comment on this question for clarity