ActivityExecutionContext.CancelActivity(Activity) Método

Definición

Llamado por una actividad compuesta para programar la cancelación de una actividad secundaria.Called by a composite activity to schedule the cancellation of a child activity. El tiempo de ejecución del flujo de trabajo deniega la cancelación de una actividad secundaria que no está en el estado Executing.The workflow runtime disallows cancellation of a child activity that is not in the Executing state.

public:
 void CancelActivity(System::Workflow::ComponentModel::Activity ^ activity);
public void CancelActivity (System.Workflow.ComponentModel.Activity activity);
member this.CancelActivity : System.Workflow.ComponentModel.Activity -> unit
Public Sub CancelActivity (activity As Activity)

Parámetros

activity
Activity

El Activitycancelado.The canceled Activity.

Excepciones

activity es null.activity is null.

activity no es un elemento secundario válido de ActivityExecutionContext.activity is not a valid child of the ActivityExecutionContext. Esto significa que o el argumento es igual al Activity asociado o que el argumento no está en estado marcado como comentario y es un elemento secundario de Activity asociado a ActivityExecutionContext.This means that either the argument is equal to the associated Activity or that the argument is not in the commented state and is a child of the Activity associated with this ActivityExecutionContext.

activity no está en el estado Executing.activity is not in the Executing state.

Se aplica a