Default Workflow Conditions (WorkflowInfo)
Applies to: SharePoint Foundation 2010
Conditions are rules that you configure to direct the flow of your workflow. They are used to compare values and perform logic checks. If a condition is satisfied with the parameters provided, Microsoft SharePoint Foundation 2010 executes a specified workflow activity.
SharePoint Foundation 2010 provides a number of default, or predefined, workflow conditions that you can use by themselves or combine to create complex business logic for your workflows.
Location of Default Workflow Conditions
Default workflow conditions are contained in the WSS.ACTIONS file, which is an XML file that lists all default conditions and actions that are available to the workflow editor. (For information about the default workflow actions that are included in the WSS.ACTIONS file, see Default Workflow Actions.) By default, the WSS.ACTIONS file is installed in the following location in SharePoint Foundation 2010:
%WSSRoot%\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\1033\Workflow
Note
Direct modification of the WSS.ACTIONS file is not recommended or supported. However, you can expand the conditions that are available to your code-free workflow editor by creating and adding additional custom .ACTIONS files to the same directory. SharePoint Foundation 2010 parses all files that have the .ACTIONS file name extension and creates a combined list that it then presents to the declarative, code-free workflow editor.
Default Conditions
The following table lists the default workflow conditions that are included with SharePoint Foundation 2010. It also includes an example rule sentence for each condition, and the fields and values that apply.
Condition |
Description |
---|---|
Compare<list or document library name> field |
Instructs the workflow designer to compare a field in the current list or document library to a specified value. Rule Sentence: If fieldequalsvalue Fields:
|
Compare any data source |
Instructs the workflow designer to compare a field in any SharePoint list or document library in the current website to a specified value. Rule Sentence: If valueequalsvalue Fields:
|
Title field contains keywords |
Used to test whether specific keywords exist in the title field of the current list or document library item that the workflow is running on. Rule Sentence: If title field contains keywords Fields:
|
Modified in a specific date span |
Checks the modified date of the item. If the modified date of a list item falls within a specified date range, this condition returns true. Rule Sentence: If modified between date and date Fields:
|
Modified by a specific person |
When a workflow is started that contains this condition, the list item is examined for last modified date. If the item was modified by the person who is specified in the workflow, this condition is satisfied and returns true. Rule Sentence: If modified by specific person Fields:
|
Created in a specific date span |
Checks the date that the item was created. If the creation date falls within a specified date range, this condition returns true. Rule Sentence: If modified between date and date Fields:
|
Created by a specific person |
When a workflow is started that contains this condition, the list item is examined for its creator. If the item was modified by the person who is specified in the workflow, the condition is satisfied and returns true. Rule Sentence: If modified by specific person Fields:
|
The file type is a specific type |
Used to evaluate whether a file is of a certain type (for example, a Microsoft Word document, a Microsoft Excel worksheet, and so on.) Rule Sentence: If the file type is specific type Fields:
|
The file size in a specific range kilobytes |
Used to evaluate whether a file is a specific size. This condition can be used to ensure that Word documents in a document library do not exceed a specific size. Rule Sentence: If the file size is between size and size kilobytes Fields:
|