[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.] Sets the status of the workflow. This workflow status displays in the status column for the workflow, and on the workflow status page in the Microsoft Windows SharePoint Services 3.0 user interface.
(Name) Required string. The default is the default name of the activity.
CorrelationToken Required System.Workflow.Runtime.CorrelationToken. For activities that affect the entire workflow, the correlation token should be bound to the correlation token of the OnWorkflowActivated activity. Therefore, for this activity, bind this property to the correlation token for the parent workflow.
Description Optional string. The default is null. Use this property to enter a description of the activity.
Enabled Required bool. Use this property to enable the activity.
MethodInvoking Optional method. Use this property to specify the method you want to run before the state is set.
State Required int. Specifies the status to set the workflow to.
Microsoft Windows SharePoint Services 3.0 reserves values up to the integer value specified in the SPWorkflowStatus.Max property. However, you can define workflow status strings for integers equal to and greater than the value of the SPWorkflowStatus.Max property in the workflow definition file.
For example, in the MetaData element of the workflow template definition file, you could add two custom workflow status strings to display:
<MetaData>
…
<StatusPageUrl>_layouts/WrkStat.aspx</StatusPageUrl>
<ExtendedStatusColumnValues>
<StatusColumnValue>My Status 1</StatusColumnValue>
<StatusColumnValue>My Status 2</StatusColumnValue>
…
</ExtendedStatusColumnValues>
…
<MetaData>
Then, to set the workflow status to 'My Status 1', set the State property to the value of the SPWorkflowStatus.Max property. To set the workflow status to 'My Status 2', set the State property to the value of the SPWorkflowStatus.Max property plus one, and so on to specify any additional custom workflow status settings.
For more information on the workflow template definition, see Workflow Definition Schema.
WorkflowId Required GUID. This property represents the GUID that the workflow engine assigns to this workflow instance when it is started. The WorkflowId properties of each activity in the workflow should be bound to this property.
Concepts
Workflow Activities for Windows SharePoint Services Overview
Workflow Initialization in Windows SharePoint Services
Correlation Tokens in Workflows
How Windows SharePoint Services Processes Workflow Activities