共用方式為


Flowchart.StartNode 屬性

定義

取得或設定當流程圖啟動時要執行的 FlowNode

public:
 property System::Activities::Statements::FlowNode ^ StartNode { System::Activities::Statements::FlowNode ^ get(); void set(System::Activities::Statements::FlowNode ^ value); };
[System.Windows.Markup.DependsOn("Variables")]
public System.Activities.Statements.FlowNode StartNode { get; set; }
[<System.Windows.Markup.DependsOn("Variables")>]
member this.StartNode : System.Activities.Statements.FlowNode with get, set
Public Property StartNode As FlowNode

屬性值

開始節點。

屬性

範例

下列程式碼範例將示範如何設定 Flowchart 活動的 StartNode。 此範例來自 使用 TryCatch 的流程圖活動中的錯誤處理 範例。

Flowchart flowChart = new Flowchart
{
    DisplayName = "Promotional Discount Calculation",
    Variables = {discount, promo, numberOfKids},
    StartNode = promoCodeSwitch,
    Nodes =
    {
        promoCodeSwitch,
        singleStep,
        mnkStep,
        mwkStep,
        discountDefault,
        flowDecision,
        discountApplied,
        discountNotApplied
    }
};

備註

必須只有一個 StartNode

適用於