We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

rohanrkt
Posts: 1
Joined: Thu Aug 23, 2012 5:24 pm

How to run batch file just after insallation phase in silent

Sir,
I want to know how to run batch file silently just after installation phase ends
and after the execution of that file the finish dialog or finish button appears.

i would also like to know is it possible to show the status bar in the dialog which shows the status of the execution of batch file
Daniel
Posts: 8283
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: How to run batch file just after insallation phase in si

Hello and welcome to Advanced Installer forums,

Thank you for your interest in Advanced Installer.
I want to know how to run batch file silently just after installation phase ends
and after the execution of that file the finish dialog or finish button appears.
If you want to run a .bat file with command window hidden, then you can use a script file (i.e. MY_SCRIPT.vbs) like this:

Code: Select all

const WindowStyleStealth  = &H20000000
set WSO = createobject("WScript.Shell")
WSO.run "%comspec% /c BAT_FILE.bat", WindowStyleStealth, false
Please keep in mind that you need to add both files (MY_SCRIPT.vbs and BAT_FILE.bat) in "Files and Folders" view in the same folder. In order to launch the .vbs file go to "Custom Actions" page and add a "Launch file or open URL" custom action with sequence, after "Install Execution Stage" -> "Add Resources" action group, like this:
  • Command: "[#MY_SCRIPT.vbs]"
Also, the .vbs custom action should run as deferred with no impersonation.
i would also like to know is it possible to show the status bar in the dialog which shows the status of the execution of batch file
In order to achieve this select the .vbs custom action and press the [Action Text...] button from "Custom Actions Properties" right pane. In the "Edit Action Properties" dialog set the "Description" field with text which you want to be displayed in the progress dialog box.

Let us know if this helped.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”