IWbemContext::Clone method (wbemcli.h)

The IWbemContext::Clone method makes a logical copy of the current IWbemContext object. This method can be useful when many calls must be made which have largely identical IWbemContext objects.

Syntax

HRESULT Clone(
  [out] IWbemContext **ppNewCopy
);

Parameters

[out] ppNewCopy

Must point to NULL on entry. It receives a pointer to the new object containing the clone of the current object. The returned pointer has a positive reference count. The caller must call IWbemServices::Release on this pointer when it is no longer needed. On error, this pointer is left unmodified, and a new object is not returned.

Return value

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

Requirements

Requirement Value
Minimum supported client Windows Vista
Minimum supported server Windows Server 2008
Target Platform Windows
Header wbemcli.h (include Wbemidl.h)
Library Wbemuuid.lib
DLL Esscli.dll; Fastprox.dll; FrameDyn.dll; FrameDynOS.dll; Wbemcomn.dll; Wbemcore.dll; Wbemess.dll; Wmipjobj.dll