共用方式為


WorkflowApplication.InstanceStore 屬性

定義

取得或設定物件,這個物件會針對目前工作流程應用程式之執行個體的存放狀態提供存取。

public:
 property System::Runtime::DurableInstancing::InstanceStore ^ InstanceStore { System::Runtime::DurableInstancing::InstanceStore ^ get(); void set(System::Runtime::DurableInstancing::InstanceStore ^ value); };
public System.Runtime.DurableInstancing.InstanceStore InstanceStore { get; set; }
member this.InstanceStore : System.Runtime.DurableInstancing.InstanceStore with get, set
Public Property InstanceStore As InstanceStore

屬性值

執行個體存放區。

範例

下列範例會建立 WorkflowApplication 執行個體,然後使用 InstanceStore 來設定 SqlWorkflowInstanceStore。 此程式代碼範例是 How to: Create and Run a Long Running Workflow 的一部分,這是 使用者入門 教學課程 [.NET Framework 4.5] 的一部分。

Activity wf = new WriteLine
{
    Text = "Hello world."
};

WorkflowApplication wfApp = new WorkflowApplication(wf);

Console.WriteLine("Id: {0}", wfApp.Id);

適用於