InstallAware for Windows Installer
 

Registry (Setup Architecture)

The Registry page allows you to create registry entries as part of your installation. You may also import existing entries directly from the system registry in this page. Registry entires may be added to a particular feature of the setup, or may be made feature-independent (so they will always install, regardless of setup features chosen for installation by the end-user at runtime).

Creating Keys and Values

There are various ways to create registry keys and values as part of your setup.

Defining New Values

You may define new values from scratch:

  1. Check the Filter Keys by Feature button.
  2. If you wish to add the values to a particular feature of your setup, choose that feature. If you prefer the values always be installed, select the Feature Independent item.
  3. In the Target Keys view, select the parent key of the new key/value pair.
  4. Right click in the Target Values view and choose New Value.
  5. The Edit Value Name/Data window appears. Populate the fields in this window to describe your new value.
  6. If you would like to create an Integer value, check the Set as Integer box. Otherwise, leave this field unchecked.
  7. Click OK to apply your changes.

This method lets you create values inside keys that are already mapped on the Target Keys structure. Also, you may only create String or Integer data types using this method. Read below for more information on how to create values inside new keys, update existing values to be placed inside new keys, and to create other data types.

Adding Registry Keys

You may add an entire registry key, along with its subkeys and values, directly into your setup. The keys to add must already be a part of your local system registry.

To add registry keys:

  1. In the Source Keys view, expand the root keys and navigate to the key you wish to add.
  2. Check the Filter Keys by Feature button.
  3. If you wish to add the keys to a particular feature of your setup, choose that feature. If you prefer the keys to be always installed, select the Feature Independent item.
  4. Click the Add Key button.

Adding Registry Values

You may add a group of registry values belonging to a registry key directly into your setup. The values to add must already be a part of your local system registry.

To add registry values:

  1. In the Source Keys view, expand the root keys and navigate to the key containing the values you wish to add.
  2. Check the Filter Keys by Feature button.
  3. If you wish to add the values to a particular feature of your setup, choose that feature. If you prefer the values to be always installed, select the Feature Independent item.
  4. In the Source Values view, highlight all values to add.
  5. Click the Add Values button.

Defining Registry Keys

You may define a new, custom registry key if it is not already a part of your local system registry. Once you have defined a key, you may follow the steps above to populate it with the values you need.

To define a new registry key:

  1. Check the Filter Keys by Feature button.
  2. If you wish to add the key to a particular feature of your setup, choose that feature. If you prefer the key to be always installed, select the Feature Independent item.
  3. In the Source Keys view, expand the root keys and click the parent key you wish to define your new key under.
  4. Right-click and choose New Key.
  5. In the New Key dialog that appers, enter the name of your new key. You may enter multiple subkey names if you wish to create a nested key. Click OK to create your key.

Importing Keys/Values

You may directly import keys and values stored in .REG files and COM servers. .REG files are created by the Registry Editor when exporting keys and values from the system registry to a file. COM servers are capable of self-registration and the data they write to the registry as part of their self registration process may be captured and added to your setup, instead of relying on their built-in self-registration mechanism.

To import keys/values:

  1. Check the Filter Keys by Feature button.
  2. If you wish to add the keys/values to a particular feature of your setup, choose that feature. If you prefer the keys/values to be always installed, select the Feature Independent item.
  3. Click the Import button.
  4. Browse to the file containing the data to import. If the file type you are looking for is not listed, select the correct type in the Files of type field.
  5. Click OK to import the registry data from the selected source.

Be sure to review the imported values and their associated data, updating references to hard-coded paths on your system with variables that will point to the actual location of files on the target system at runtime.

Updating Keys/Values

Updating Keys

To update a registry key (along with all the values inside it):

  1. Uncheck the Filter Keys by Feature button to see all registry keys and values being created by your setup.
  2. In the Target Keys field, right click the key to update and choose Edit.
  3. The Write Multiple Registry Values dialog opens. Update the dialog fields as appropriate.
  4. Click OK to save your changes.

If the Edit option is disabled when you right click the key, this indicates that the key you are updating is not being explicitly created by your setup (you may be creating a subkey of the highlighted key instead).

When you update a registry key using this method, subkeys of that registry key are not affected.

Updating Values

You may update single registry values, or select multiple values and update them simultaneously (in this case, you may change the registry root and parent key of all selected values in a single pass):

  1. Uncheck the Filter Keys by Feature button to see all registry keys and values being created by your setup.
  2. In the Target Values field, highlight all values to update.
  3. Right click the selection and choose Edit Values.
  4. If you chose multiple values, the Write Multiple Registry Values dialog opens. If you chose a single value, the Write Registry dialog opens. Both dialogs are similar, with some fields disabled in the former. Update the existing dialog fields as appropriate. If you chose a single value, you may update its data and data type here.
  5. Click OK to save your changes.

The parent key of the values updated may disappear if there are no longer any values being created underneath it. To preserve at least the key, be sure to create at least the default registry value (the value underneath the key with an empty value name).

Removing Keys/Values

Removing Keys

To remove a registry key (along with all the values inside it):

  1. Uncheck the Filter Keys by Feature button to see all registry keys and values being created by your setup.
  2. In the Target Keys field, right click the key to delete and choose Delete.

If the Delete option is disabled when you right click the key, this indicates that the key you are updating is not being explicitly created by your setup (you may be creating a subkey of the highlighted key instead).

When you delete a registry key using this method, subkeys of that registry key are not affected.

Deleting Values

You may delete single registry values, or select multiple values and delete them simultaneously:

  1. Uncheck the Filter Keys by Feature button to see all registry keys and values being created by your setup.
  2. In the Target Values field, highlight all values to delete.
  3. Right click the selection and choose Delete Values.

The parent key of the values updated may disappear if there are no longer any values being created underneath it. To preserve at least the key, be sure to leave at least the default registry value (the value underneath the key with an empty value name).

Scripting Details

The two-way integrated IDE emits or updates the underlying setup script every time the visual view is used. If you are using InstallAware scripting in your setups, the following information identifies the changes made by this visual page to your setup script.

Commands Used

This page emits the following types of scripting commands: Write Registry. Additional general scripting commands may be emitted.

Commands Required

This page requires the following scripting commands to be already present in your setup script: Apply Install.