Επεξεργασία

Κοινή χρήση μέσω


Installer.ProvideQualifiedComponent method

The ProvideQualifiedComponent method of the Installer object returns the full component path and performs any necessary installation. If necessary, this method prompts for the source and increments the usage count for the feature.

Syntax

Installer.ProvideQualifiedComponent(
  Category,
  Qualifier,
  InstallMode
)

Parameters

Category

Specifies the component ID for the requested component. This may not be the GUID for the component itself but rather a server that provides the correct functionality, as in the ComponentId column of the PublishComponent table.

Qualifier

Specifies a qualifier into a list of advertising components (from PublishComponent table).

InstallMode

Defines the installation mode. This parameter can be one of the values shown in the following table.

InstallMode Meaning
msiInstallModeDefault
0
Provides the component, performing any necessary installation.
msiInstallModeExisting
–1
Provides the component only if the feature exists; otherwise returns an empty string. This mode verifies the existence of the component's key file.
msiInstallModeNoDetection
–2
Provides the component only if the feature exists; otherwise returns an empty string. This mode only checks that the component is registered but does not verify the existence of the component's key file.
msiInstallModeNoSourceResolution
–3
Provides the component path only if the feature exists with an InstallState parameter of msiInstallStateLocal. This checks the component's registration but does not verify the existence of the component's key file.
combination of the msiReinstallMode flags
 
Calls ReinstallFeature to reinstall the feature using this parameter for the ReinstallMode parameter, and then provides the component.

 

Return value

This method does not return a value.

Requirements

Requirement Value
Version
Windows Installer 5.0 on Windows Server 2012, Windows 8, Windows Server 2008 R2 or Windows 7. Windows Installer 4.0 or Windows Installer 4.5 on Windows Server 2008 or Windows Vista. Windows Installer on Windows Server 2003 or Windows XP
DLL
Msi.dll
IID
IID_IInstaller is defined as 000C1090-0000-0000-C000-000000000046

See also

MsiProvideQualifiedComponent