MSI Factory 2.3

Key Paths

Key Paths

Previous topic Next topic  

Key Paths

Previous topic Next topic  

MSI Factory

Every component must have a key path. The key path is a specific resource that Windows Installer will use to determine whether the component already exists on the target system.

The key path for a component can be one of the following:

- the destination folder of the component (in MSI Factory this means selecting the component as the key path)

- a file in the component

- a Registry value in the component

- an ODBC data source in the component

A component can only have one key path, and it should be unique to that component. No components should have the same key path unless it is a destination folder. Otherwise the presence of one component will prevent the other from being installed. (Note that setting the same destination folder as the key path for more than one component is an exception to this rule.)

If you do not explicitly set the key path for a component, MSI Factory will attempt to choose an appropriate key path for you.

Whenever an application is launched using an advertised shortcut, the Windows Installer service will verify the existence of the application's key path items. If for example a key path file is missing, the entire feature related to that component will be reinstalled. Because Windows Installer uses the key paths to trigger this self-repair behaviour, it is very important to choose your key paths carefully.

Note: When installing files to per-user locations, such as the Desktop folder, you must use a registry value under HKEY_CURRENT_USER as the key path in order to pass ICE38 validation. If you do not explicitly select a key path for a component, MSI Factory will attempt to take care of this for you by adding a per-user registry value key path.

More Information

MSDN Online: Component Table

MSDN Blogs: Windows Installer Components Introduction

Wikipedia: Windows Installer

Aaron Stebner's WebLog: How Windows Installer handles file replacement logic for versioned and unversioned files

InstallSite MSI FAQ: Windows Installer launches unexpectedly, for no obvious reason

MSDN Online: Ice Reference

WiX Help File: Component Element


Learn More: Indigo Rose Software - MSI Factory - Buy Now - Contact Us