InstallShield 2019 » InstallScript Language Reference
The OnShowUI event drives the UI sequence and file transfer of the installation.
The OnShowUI event is called directly by the framework to initiate the UI sequence and file transfer of the installation. By default, this event displays UI that informs the end user that maintenance has been completed successfully.
Note • This event is not called automatically in a program...endprogram style installation.
Syntax
OnShowUI ( );
Parameters
None.
Return Values
None.
Additional Information
You can easily convert a procedural script to an event-based script by performing the following steps. If you do this, neither the user interface event handlers (OnFirstUIBefore, OnMaintUIBefore, OnUpdateUIBefore, OnFirstUIAfter, OnMaintUIAfter, and OnUpdateUIAfter) nor OnMoveData are called; but all other feature event handlers are called as appropriate.
To convert a procedure script to an event-based script:
1. | Open your project in InstallShield; when you are prompted to convert it, click Yes. |
2. | Open the script and change the following line: |
program
to this:
function OnShowUI
begin
3. | Also change the following line: |
endprogram
to this:
end
4. | If you are planning to display any custom objects that include a user interface (objects provided with InstallShield do not), add a call to ShowObjWizardPages to your dialog sequence at the location where you want any object UI to be shown: |
ShowObjWizardPages( nResult );
This function can be called before or after file transfer; the appropriate object event is called based on whether or not file transfer has occurred and on the value of the MAINTENANCE system variable.
5. | Make the changes needed to compile the script in InstallShield. |
You can also customize the OnBegin and OnEnd events if you wish.
Why This Works
In InstallScript, most installation events are driven by the main UI event, OnShowUI. When you replace the default code in this event with the code in your program…endprogram block, you are basically providing a custom UI sequence. Note that since OnShowUI is called when the installation is run, your installation behaves just like it did when it was a program…endprogram script.
Launching an InstallScript Package in an Advanced UI or Suite/Advanced UI Installation
Note that when an Advanced UI or Suite/Advanced UI installation launches an InstallScript package, the OnSuiteShowUI event is called instead of the OnShowUI event.
See Also
Adding an InstallScript Package to an Advanced UI or Suite/Advanced UI Project
InstallShield 2019 Help LibraryApril 2019 |
Copyright Information | Flexera |