Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

IWbemHiPerfEnum::AddObjects method

The IWbemHiPerfEnum::AddObjects method adds the supplied instance objects to the enumerator.

Syntax


HRESULT AddObjects(
  long lFlags,
  [in]  ULONG uNumObjects,
  [in]  long *apIds,
  [in]  IWbemObjectAccess *apObj
);

Parameters

lFlags

Reserved. This parameter must be 0.

uNumObjects [in]

Number of items in the object and the number of identifiers in the parameter.

apIds [in]

Pointer to an array of integers that contains a unique identifier for each object in the object array.

apObj [in]

Pointer to an array of instance objects to add to the enumerator.

Return value

This method returns an HRESULT indicating the status of the method call. The following table lists the value contained within an HRESULT.

Return codeDescription
WBEM_S_NO_ERROR

The method was successful.

WBEM_E_FAILED

A specified index already exists.

WBEM_E_OUT_OF_MEMORY

Memory could not be allocated.

WBEM_E_ACCESS_DENIED

Insufficient access to perform the operation.

WBEM_S_TIMEDOUT

The enumerator was busy with another operation.

 

Remarks

If an identifier already exists, WBEM_E_FAILED is returned. The refresher identifiers can be used to remove objects later.

Examples

For script code examples, see WMI Tasks for Scripts and Applications and the TechNet ScriptCenter Script Repository.

For C++ code examples, see WMI C++ Application Examples.

Requirements

Minimum supported client

Windows XP

Minimum supported server

Windows Server 2003

Header

Wbemcli.h (include Wbemidl.h)

Library

Wbemuuid.lib

DLL

Wbemperf.dll

See also

IWbemHiPerfEnum

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.