Advertise method
Collapse the table of content
Expand the table of content

Advertise method of the Win32_Product class

The Advertise WMI class method advertises an associated Win32_Product instance using the installation package provided through the PackageLocation parameter and any supplied command line options.

Note  For more information about support or requirements for installation on a specific operating system, see Operating System Availability of WMI Components.
 

This topic uses Managed Object Format (MOF) syntax. For more information about using this method, see Calling a Method.

Syntax


uint32 Advertise(
  [in] string PackageLocation,
  [in] string Options
);

Parameters

PackageLocation [in]

The path to the package to be advertised.

Options [in]

Command line options for the advertisement. Format as property=setting.

AllUsers

Indicates whether the operation should be applied to all users on the computer. If FALSE, the operation is applied to only the current user. This parameter is no longer used.

Return value

Return codeDescription
0

Successful completion

2147549445

RPC Server Fault Error

 

Requirements

Minimum supported client

Windows XP

Minimum supported server

Windows Server 2003

Namespace

Root\CIMV2

MOF

Msi.mof

DLL

Msiprov.dll

See also

Installed Applications Classes
Win32_Product
WMI Tasks: Computer Software

 

 

Community Additions

ADD
Show:
© 2016 Microsoft