Share this page

# InvokeStaticGenericMethod

.NET Vuser Functions

Invoke a static generic method.

    object InvokeStaticGenericMethod(Type type, string methodName, int metadataToken, Type[] genericArguments, object[] parameters);

type | The method type.
methodName | The name of the generic method.
metadataToken | The metadataToken of the method.
genericArguments | The generic arguments with which to make the method invokable.
parameters | The method parameters.

InvokeStaticGenericMethod invokes a static generic method indicated by its name, type, and metadataToken. It returns the result of the method invocation..

Note: Do not add this function manually to a script. It is generated by VuGen automatically.

## Parameterization

Parameterization is not applicable to this function.

## Example

This example invokes the static generic method, MyTest.

    object[] parameters = new object[] { t1 };
    LrReplayUtils.InvokeStaticGenericMethod(typeof(AccessModifiers.GenericTypeTest<int>), "MyTest", 100663410, new System.Type[] {typeof(string)}, parameters);

Tips to improve your search results... VuGen Function Reference Version 26.1 Function Reference 26.1 All View Local Help Center View Online Help Center Version: