ExecutionType 列舉

定義

警告

The System.Workflow.* types are deprecated. Instead, please use the new types from System.Activities.*

指定活動的執行模式。

C#
public enum ExecutionType
C#
[System.Obsolete("The System.Workflow.* types are deprecated.  Instead, please use the new types from System.Activities.*")]
public enum ExecutionType
繼承
ExecutionType
屬性

欄位

Parallel 1

平行執行活動。

Sequence 0

循序執行活動。 每個活動會在上一個活動完成執行後,依序執行活動。

範例

下列程式碼範例顯示如何使用 ExecutionType 列舉設定活動的執行模式。 這個程式碼範例是 Simplereplicatorworkflow.cs 檔案中<複寫器 SDK>範例的一部分。 如需詳細資訊,請參閱 使用複寫器

C#
this.CanModifyActivities = true;
System.Workflow.ComponentModel.ActivityBind activitybind1 = new System.Workflow.ComponentModel.ActivityBind();
this.throwActivity1 = new System.Workflow.ComponentModel.ThrowActivity();
activitybind1.Name = "ThrowWorkflow";
activitybind1.Path = "ThrownException";
//
// throwActivity1
//
this.throwActivity1.Name = "throwActivity1";
this.throwActivity1.SetBinding(System.Workflow.ComponentModel.ThrowActivity.FaultProperty, ((System.Workflow.ComponentModel.ActivityBind)(activitybind1)));
//
// ThrowWorkflow
//
this.Activities.Add(this.throwActivity1);
this.Name = "ThrowWorkflow";
this.CanModifyActivities = false;

備註

注意

此資料討論已被汰換的類型及命名空間。 如需詳細資訊,請參閱 Windows Workflow Foundation 4.5 中即將淘汰的類型

適用於

產品 版本 (已淘汰)
.NET Framework 3.0, 3.5, 4.0 (4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8)