WorkflowApplicationEventArgs.InstanceId 属性

定义

工作流实例的唯一标识符。The unique identifier of the workflow instance.

public:
 property Guid InstanceId { Guid get(); };
public Guid InstanceId { get; }
member this.InstanceId : Guid
Public ReadOnly Property InstanceId As Guid

属性值

Guid

一个唯一标识符。A unique identifier.

示例

下面的代码示例检查传递给 WorkflowApplicationEventArgs 实例的 Unloaded 处理程序的 WorkflowApplication,并显示已卸载的工作流的 InstanceIdThe following code example inspects the WorkflowApplicationEventArgs passed into the Unloaded handler of a WorkflowApplication instance and displays the InstanceId of the workflow that was unloaded.

wfApp.Unloaded = delegate(WorkflowApplicationEventArgs e)
{
    Console.WriteLine("Workflow {0} unloaded.", e.InstanceId);
};

适用于