Project 2000. Local and Upgrade Installation, страница 6

Component detection information is stored in the registry at the following location: HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\Currentversion\Installer \Components


Features

A feature is a collection of one or more components. When you perform a custom installation, you see a list of features to choose to install (any item on the Feature tree). For example, Add-ins is a feature in Microsoft Project. Features can share components.


Products

As you would expect, a product represents a single product. “Microsoft Project” is a product. There exists one package file (.MSI database) for each product. For Microsoft Project 2000, this file is INSTALL.MSI. Each product has a unique product code. Products consist of one or more features.

Note

The product code for Microsoft Project 2000 is 8061EFD2ACDB1D117BEA000CF49BF2D3.

The product code for Project Central is 00A52CA4AE703D116815000CF4E6902F.

How Component Detection Works

The Windows Installer uses component detection to determine whether a component is available and is in good working order. The Window Installer performs component detection every time a product that was installed by the installer attempts to use a feature. One use of component detection is determining whether a component being installed is already installed and a running product requesting a component, which in turn triggers component detection. A single component contains the exact same set of resources, regardless of which product ships it. Also, a resource cannot be shared across components. This prevents collisions between components where the components should have been unique from each other.

One of the objects that make up a component can be designated as the “keypath” for that component. Typically this object is a file (for example, winproj.exe), but it can be a registry key. The keypath represents two things:

1.  The keypath represents the path to a given component. When an application requests the path to the component, the Window Installer returns the path to the keypath resource (usually a path to a file).

2.  The keypath represents the only resource the Window Installer checks for existence to see whether the component is properly installed.

When the keypath resource is missing, the Window Installer treats the component as broken and triggers a reinstall of the missing component.


Component Detection Example

A user wants Rocky, the Office Assistant that was not originally installed. After starting setup in maintenance mode, the installer checks the following registry key:

Hkey_Local_Machine\Software\Microsoft\Windows\CurrentVersion\Installer\Components\COMPRESSED_COMPONENT_GUID\COMPRESSED_PRODUCT_GUID = c:\path\to\keypath

When the keypath exists at the specified path, the installer informs the calling application (i.e. Microsoft Project) of the path and the assistant is loaded.

When the keypath does not exist, the installer returns the appropriate error code, which in this case is INSTALLSTATE_ABSENT.

Registry Keys

The installer then looks in the following registry hives to determine whether Project is installed per-user or per-computer, and whether it is a managed application. A managed application is an application assigned on Microsoft® Windows® 2000 by an administrator via the App Deployment service. Per-User means that each user on the machine has a profile enabled. For Microsoft® Windows® 95/Microsoft® Windows® 98, user profiles must be turned on in order to use per-user. For Microsoft® Windows NT® 4.0 and Windows 2000, user profiles are turned on by default. Per-computer means that the applications are the same for all users and no profiles are enabled.