IGPMGPO::SetWMIFilter method

Links the GPMWMIFilter object to the current Group Policy object (GPO). This method can also be used to unlink existing WMI filters from the GPO.

Syntax


HRESULT SetWMIFilter(
  [in]               objGPMWMIFilter,
  [in] IGPMWMIFilter *pIGPMWMIFilter
);

Parameters

objGPMWMIFilter [in]

GPMWMIFilter object to associate with the current GPO. Passing NULL in this parameter unlinks any existing WMI filters.

pIGPMWMIFilter [in]

Pointer to the WMI filter to associate with the current GPO. Passing NULL in this parameter unlinks any existing WMI filters.

Return value

JScript

Returns S_OK if successful. Returns a failure code if an error occurs.

VB

Returns S_OK if successful. Returns a failure code if an error occurs.

Requirements

Minimum supported client

Windows Vista

Minimum supported server

Windows Server 2008

Header

Gpmgmt.h

IDL

Gpmgmt.idl

DLL

Gpmgmt.dll

IID

IID_IGPMGPO is defined as 58CC4352-1CA3-48E5-9864-1DA4D6E0D60F

See also

IGPMGPO
IGPMWMIFilter

 

 

Show: