InvokeMethod.MethodName Propiedad

Definición

Nombre del método que se va a invocar cuando se ejecuta la actividad.

public:
 property System::String ^ MethodName { System::String ^ get(); void set(System::String ^ value); };
public string MethodName { get; set; }
member this.MethodName : string with get, set
Public Property MethodName As String

Valor de propiedad

El nombre del método.

Ejemplos

En el ejemplo de código siguiente se muestra cómo establecer la propiedad MethodName de una InvokeMethod actividad. Este ejemplo procede del ejemplo Using the InvokeMethod Activity (Usar la actividad InvokeMethod ).

new InvokeMethod
{
    TargetObject = new InArgument<TestClass>(ctx => testClass),
    MethodName = "InstanceMethod",
    Parameters =
    {
        new InArgument<string>("My favorite number is"),
        new InArgument<int>(42),
        new InArgument<string>("first item of the param array"),
        new InArgument<string>("second item of the param array"),
        new InArgument<string>("third item of the param array")
    }
},

Comentarios

El método invocado debe declararse como público.

Se aplica a