Setting Custom Shell Properties

InstallShield 2016

Project • This information applies to the following project types:

Basic MSI
DIM
InstallScript
InstallScript MSI
Merge Module
MSI Database
MSM Database
Transform

Project-specific differences are noted where applicable.

InstallShield lets you specify one or more shortcut properties that need to be set by the Windows Shell at run time. The properties that the Shell can set are defined in propkey.h, which is part of the Windows SDK.

Note that the method for preventing the highlight behavior varies, depending on the project type that you are using.

Instructions for Windows Installer–Based Projects

For Basic MSI, DIM, InstallScript MSI, Merge Module, MSI Database, MSM Database, and Transform projects, use the Shell Properties setting to set one or more Shell properties.

To set a Shell property for a shortcut that is in your project:

1. In the View List under System Configuration, click Shortcuts.
2. In the Shortcuts explorer, select the shortcut that you want to configure. The shortcut’s settings are displayed in the right pane.
3. In the Shell Properties setting, click the Add New Shell Shortcut Property button, and then click Custom Property. InstallShield adds a new Key Name setting, plus additional rows of related settings under it, with placeholder text.
4. Configure each of the settings as needed.

You can add multiple properties for the shortcut if necessary.

Windows Installer 5 introduced support for the Shell shortcut properties. Earlier versions of Windows Installer ignore these properties.

For more information about configuring shortcut properties, see MsiShortcutProperty Table in the Windows Installer Help Library.

Note that for Windows Installer–based installations, some end users have reported run-time warnings or errors with a message such as the following one when Windows Installer is installing a shortcut that configures Shell properties:

Property [1] for shortcut ’[2].lnk’ could not be set.

In the aforementioned message, [1] is the name of the Shell property that Windows Installer is attempting to set, and [2].lnk is the name of the shortcut file. In such cases, it appears that the .lnk file could be locked by a different process.

InstallScript Language Support

The following InstallScript functions enable you to configure Shell properties in InstallScript projects and in other project types:

CreateShortcut
SetShortcutProperty

See Also