共用方式為


HandleExternalEventActivity.Roles 屬性

定義

取得或設定對工作流程角色集合的參考。

public:
 property System::Workflow::Activities::WorkflowRoleCollection ^ Roles { System::Workflow::Activities::WorkflowRoleCollection ^ get(); void set(System::Workflow::Activities::WorkflowRoleCollection ^ value); };
public System.Workflow.Activities.WorkflowRoleCollection Roles { get; set; }
member this.Roles : System.Workflow.Activities.WorkflowRoleCollection with get, set
Public Property Roles As WorkflowRoleCollection

屬性值

工作流程角色的集合。

範例

下列程式碼範例示範如何建立與設定 HandleExternalEventActivity 類別的值。 這個程式碼範例是 DocumentApprovalWorkflow.cs 檔案中<RaiseEventToLoadWorkflow SDK>範例的一部分。 如需詳細資訊,請參閱 引發事件以載入工作流程

this.Car.Name = "Car";
this.Car.ExecuteCode += new System.EventHandler(this.Car_ExecuteCode);
this.Car.SetValue(System.Workflow.Activities.ConditionedActivityGroup.WhenConditionProperty, codecondition1);
codecondition2.Condition += new System.EventHandler<System.Workflow.Activities.ConditionalEventArgs>(this.AirlineCondition);
Me.Car.Name = "Car"
AddHandler Car.ExecuteCode, AddressOf Me.Car_ExecuteCode
Me.Car.SetValue(System.Workflow.Activities.ConditionedActivityGroup.WhenConditionProperty, codecondition1)
AddHandler codecondition2.Condition, AddressOf Me.AirlineCondition

備註

WorkflowRoleCollection 限制一組使用者,這組使用者可透過 HandleExternalEventActivity 活動將訊息傳送至工作流程執行個體。

適用於

另請參閱