ICallIndirect::CallIndirect method (callobj.h)

Invokes one of the methods in the interface with an indirect reference to the arguments of the invocation.

Syntax

HRESULT CallIndirect(
  [out] HRESULT *phrReturn,
  [in]  ULONG   iMethod,
  [in]  void    *pvArgs,
  [out] ULONG   *cbArgs
);

Parameters

[out] phrReturn

The value returned from the invocation of the method.

[in] iMethod

The method number to be invoked.

[in] pvArgs

A pointer to the stack frame with which to make the invocation. Details of the exact representation of this stack frame are processor-architecture specific.

[out] cbArgs

The number of bytes to be popped from the stack to clear the stack of arguments to this invocation.

Return value

This method can return the following values.

Return code Description
S_OK
The method completed successfully.
E_UNEXPECTED
An unexpected error has occurred.

Requirements

Requirement Value
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header callobj.h

See also

ICallIndirect