Windows Installer, Java Installer, Freeware Installer
Home|Contact|Site Map|TOC|Search
Download  Features   Java  Licensing  Purchase  Testimonials  Support  Forums

Creating a New Install Dialog

The tutorial will guide you step by step in creating a new install dialog using the Advanced Installer Dialog Editor.

Let's suppose that you want to create a package for a client type application. In order to properly configure the client you will need to obtain from the user additional information like: server address, port number, firewall settings etc. and store it in the registry.

The information will be retrieved with the use of a custom dialog.

  1. Creating the project.
  2. Adding the dialog to the project
  3. Customizing the dialog appearance
  4. Adding controls on the dialog.
  5. Associating properties with controls
  6. Adding registry entries

Creating the project.

Create an enterprise project.

Add the necessary files to the package. In order to simulate the client application any EXE file will do. For more details please see the Professional Installation tutorial.

Adding the dialog to the project

After adding the files to the package it is time to create the custom dialog.

DialogsSwitch to the Dialogs page.

The dialog should be displayed during a normal installation so we will add it in the "First Time Install" section of the "Install Sequence" tree, under the FolderDlg dialog (this dialog prompts the user to specify an install location).

New DialogSelect "FolderDlg" in the tree and use the [ New Dialog ] toolbar button. A new dialog will appear in the "First Time Install" tree. It will also be displayed in the middle pane.

Customizing the dialog appearance

Select the dialog and from the context menu choose the "Properties" option. In the right pane a Properties list will appear.

Make the following modifications to the dialog properties:

Dialog Name = SettingsDlg

You will notice that the name of the dialog will be updated in the tree.

Now it is time to change the default texts from the dialog. Using the Properties list change "New Dialog" to "Settings Dialog" and "New Dialog Description..." to "Application Settings"

BuildBuild and run the package. In the install wizard the dialog will appear like:

New Dialog

Adding controls on the dialog.

In order to retrieve the server address and port number we will use two edit fields grouped by a group box. Also we will add a control that will specify the firewall settings. A check box control will be used.

ToolboxUse the [ Toolbox ] toolbar button to display the toolbox and add the controls to the dialog. Customize them so they will look something like:

New Dialog

Associating properties with controls

After retrieving the information from the controls we will use properties to store it. Some of the controls have associated properties. We will edit the name of those properties so they will reflect the purpose of the control.

Select the first edit field from the dialog. The Properties list will be updated with the control's properties. Edit the "Property Name" field to SERVER_ADRESS.

Do the same for the second edit field and set it's associated property to PORT_NUMBER.

These two properties will contain the text entered by the used in the edit fields.

In case of the check box control in addition to the property name you will have to specify the following attributes:

  • Default Value - The value of the property before the check box is ticked.
  • Value - The value of the property after the check box is ticked.

The fields will be:

Property Name = FIREWALL_SETTINGS
Value = Yes
Default Value = <blank>

NoteIt you specify a default value for a check box property, by default the check box will appear ticked so we will leave the "Default Value" field blank.

BuildBuild and run the project

Adding registry entries

As said before the gathered information will be stored in the Registry. Create the necessary registry entries to store the value of the SERVER_ADRESS, PORT_NUMBER and FIREWALL_SETTINGS properties as described in the Professional Installation tutorial.

BuildAgain build and run the project. Check out the registry. You will find the specified information stored.

Privacy Policy | Windows Installer | Search Engine Ranking | Link Analyzer