An Installer object must be initially created to load the automation support that is required for COM to access the installer functions. This object provides wrappers to create the top-level objects and access their methods.
You can create the Installer object from the ProgId "WindowsInstaller.Installer".
Methods
The Installer object defines the following methods.
Method | Description |
---|---|
Adds a source to the list of valid network sources in the sourcelist. |
|
Advertises an installation package. |
|
Advertises an installation package. |
|
Invokes an installation and sets the PATCH property to the path of the patch package for each product listed by the patch package as eligible to receive the patch. |
|
Applies one or more patches to products eligible to receive the patch. Sets the PATCH property to the path of the patch packages provided. |
|
Removes all network sources from the sourcelist. |
|
Invokes a user interface wizard sequence that collects and stores both user information and the product code. |
|
Configures the installed state of a product feature. |
|
Installs or uninstalls a product. |
|
Generates an advertise script. |
|
Returns a new Record object with the requested number of fields. |
|
Enables logging of the selected message type for all subsequent installation sessions in the current process space. |
|
Extracts information from a patch as an XML string. |
|
Takes the path to a file and returns a 128-bit hash of that file. |
|
Takes the path to a file and returns a SAFEARRAY of bytes that represents the hash or the encoded certificate. |
|
Returns the size of the specified file. |
|
Returns the version string or language string of the specified path. |
|
Forces the installer to search the source list for a valid product source the next time a source is required. |
|
Opens an installer package and initializes an installation session. |
|
Returns a Record object that contains error parameters for the most recent error from the function that produced the error record. |
|
Opens an existing database or creates a new one. |
|
Opens an installer package for use with functions that access the product database and install engine. |
|
Opens an installer package for an installed product using the product code. |
|
Returns the installed path of an assembly. |
|
Returns the full component path and performs any necessary installation. |
|
Returns the full component path and performs any necessary installation. |
|
Reads information about a specified registry key of value. |
|
Reinstalls features or corrects problems with installed features. |
|
Reinstalls a product or corrects installation problems in an installed product. |
|
Removes one or more patches to products eligible to receive the patch. |
|
Increments the usage count for a particular feature and returns the installation state for that feature. |
Properties
The Installer object defines the following properties.
Property | Access type | Description |
---|---|---|
Read-only | Returns a RecordList object that lists products that use a specified installed component. Windows Installer 4.5 and earlier: Not supported. |
|
Read-only | Returns a StringList object enumerating the set of clients of a specified component. |
|
Read-only | Returns the full path to an installed component. |
|
Read-only | Returns a RecordList object that gives the full path of a specified installed component. Windows Installer 4.5 and earlier: Not supported. |
|
Read-only | Returns a StringList object enumerating the set of registered qualifiers for the specified component. |
|
Read-only | Returns a StringList object enumerating the set of installed components for all products. |
|
Read-only | Returns a RecordList object that lists installed components. Windows Installer 4.5 and earlier: Not supported. |
|
Read-only | The string value for an environment variable of the current process. |
|
Read-only | Specifies the parent feature of a feature. |
|
Read-only | Returns a StringList object enumerating the set of published features for the specified product. |
|
Read-only | Returns the installed state of a feature. |
|
Read-only | Returns the number of times that the feature has been used. |
|
Read-only | Returns the date that the specified feature was last used. |
|
Read-only | Returns a number that represents the combined file attributes for the designated path to a file or folder. |
|
Read-only | Returns a StringList object that contains all the patches applied to the product. |
|
Read-only | Enumerates a collection of Patch objects. |
|
Read-only | Returns a StringList object that contains a list of files that can be updated by the provided list of patches. |
|
Read-only | Returns information about a patch. |
|
Read-only | Returns the semicolon delimited list of transforms that are in the specified patch package and applied to the specified product. |
|
Read-only | Returns True if the product is managed or False if the product is not managed. |
|
Read-only | Returns the value of the specified attribute for an installed or published product. |
|
Read-only | Returns the value of the specified attribute that is stored in an advertise script. |
|
Read-only | Returns a StringList object enumerating the set of all products installed or advertised for the current user and machine. |
|
Read-only | Enumerates a collection of Product objects. |
|
Read-only | Returns the install state information for a product. |
|
Read-only | Returns a text string that describes the qualified component. |
|
Read-only | Returns a StringList object enumerating the set of all products installed or advertised for the current user and machine with a specified UpgradeCode property in their property table. |
|
Read-only | Examines a shortcut and returns its product, feature name and component if available. |
|
Read-only | Returns a SummaryInfo object that can be used to examine, update and add properties to the summary information stream of a package or transform. |
|
Read-only | Indicates the type of user interface to be used when opening and processing subsequent packages within the current process space. |
|
Read-only | Returns the string representation of the current version of Windows Installer. |
Requirements
Version | Windows Installer 5.0 on 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, Windows XP, and Windows 2000 |
---|---|
DLL | Msi.dll |
IID | IID_IInstaller is defined as 000C1090-0000-0000-C000-000000000046 |
See Also
Send comments about this topic to Microsoft
Build date: 8/13/2009
© 2009 Microsoft Corporation. All rights reserved.