ICorDebugEval2::CallParameterizedFunction Method

Sets up a call to the specified ICorDebugFunction, which can be nested inside a class whose constructor takes Type parameters, or can itself take Type parameters.


HRESULT CallParameterizedFunction (  
    [in] ICorDebugFunction     *pFunction,  
    [in] ULONG32               nTypeArgs,  
    [in, size_is(nTypeArgs)] ICorDebugType *ppTypeArgs[],  
    [in] ULONG32               nArgs,  
    [in, size_is(nArgs)] ICorDebugValue *ppArgs[]  


[in] A pointer to an ICorDebugFunction object that represents the function to be called.

[in] The number of arguments that the function takes.

[in] An array of pointers, each of which points to an ICorDebugType object that represents a function argument.

[in] The number of values passed in the function.

[in] An array of pointers, each of which points to an ICorDebugValue object that represents a value passed in a function argument.


CallParameterizedFunction is like ICorDebugEval::CallFunction except that the function may be inside a class with type parameters, may itself take type parameters, or both. The type arguments should be given first for the class, and then for the function.

If the function is in a different application domain, a transition will occur. However, all type and value arguments must be in the target application domain.

Function evaluation can be performed only in limited scenarios. If CallParameterizedFunction or ICorDebugEval::CallFunction fails, the returned HRESULT will indicate the most general possible reason for failure.


Platforms: See System Requirements.

Header: CorDebug.idl, CorDebug.h

Library: CorGuids.lib

.NET Framework Versions: Available since 2.0