SdSetupTypeEx Example

InstallShield 2014 ยป InstallScript Language Reference

Project: This information applies to InstallScript MSI projects.

/*--------------------------------------------------------------*\

*

* InstallShield Example Script

*

* Demonstrates the SdSetupTypeEx function.

*

* The SdSetupTypeEx function displays a dialog that enables

* the end user to select the setup type when you specify setup

* types beyond Complete and Custom. The dialog

* displays the names of the setup types you create in the IDE's

* Setup Types view.  

*

* This sample sets the default setup type in the SdSetupTypeEx

* dialog to "Complete".

*

\*--------------------------------------------------------------*/

 

#include "ifx.h"

 

function OnBegin()

    STRING szTitle, szMsg, szReserved, svSetupType;

    NUMBER nReserved;

begin

    // Disable the Back button in setup dialogs.

    Disable (BACKBUTTON);

  

    // Set up the variables to pass as parameters to SdSetupTypeEx.

    szTitle = "SdSetupTypeEx Sample";

    szMsg = "";

    szReserved  = "";

  

    // Specifies a default setup type (as specified in the Setup Type

    // view) and returns the setup type selected by the end user

    svSetupType = "Complete";

    nReserved   = 0;

    

    // Display the SdSetupTypeEx dialog.

    SdSetupTypeEx(szTitle, szMsg, szReserved, svSetupType, nReserved);

    

    // Display a MessageBox with the setup type selected by the end user

    MessageBox("Setup Type selected: " + svSetupType, 0);

 

end;