IWSManResourceLocator::AddSelector method (wsmandisp.h)

Adds a selector to the ResourceLocator object. The selector specifies a particular instance of a resource. You can provide an IWSManResourceLocator object instead of specifying a resource URI in IWSManSession object operations such as Get, Put, or Enumerate.

Syntax

HRESULT AddSelector(
  [in] BSTR    resourceSelName,
  [in] VARIANT selValue
);

Parameters

[in] resourceSelName

The selector name. For example, when requesting WMI data, this parameter is the key property for a WMI class.

[in] selValue

The selector value. For example, for WMI data, this parameter contains a value for a key property that identifies a specific instance.

Return value

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Requirements

   
Minimum supported client Windows Vista
Minimum supported server Windows Server 2008
Target Platform Windows
Header wsmandisp.h
Library WSManDisp.tlb
DLL WSMAuto.dll

See also

IWSManResourceLocator

ResourceLocator.AddSelector