ControlInvokeMethod Method
The method to invoke.
The arguments passed to the method. Zero or more arguments, passed as a comma-delimited list of values. Pass parameters only of data types that can be stored in a Variant.
Invokes a method of a control that is not thread-safe.
Remarks
If the InvokeRequired Property of a Control in a Windows Form is true, it is bound to a specific thread. Use this method to invoke the methods of such a source control.

For more information, see the MSDN documentation for System.Windows.Control.InvokeRequired.

For a Custom Server running in the UFT context, pass only serialized types. If one of the objects in the list is not serialized, ControlInvokeMethod fails.

Syntax
'Declaration
 
Protected Function ControlInvokeMethod( _
   ByVal sMethod As System.String, _
   ByVal ParamArray list() As System.Object _
) As System.Object
protected System.object ControlInvokeMethod( 
   System.string sMethod,
   params System.object[] list
)

Parameters

sMethod
The method to invoke.
list
The arguments passed to the method. Zero or more arguments, passed as a comma-delimited list of values. Pass parameters only of data types that can be stored in a Variant.

Return Value

The object returned by the invoked method.