Navigation:  User Guide for PaperSave for Blackbaud's Student Information System > PaperSave Configuration > PaperSave Settings > Workflows > Workflow 1.0 > Using States and Activities >

IfElseActivity

Previous pageReturn to chapter overviewNext page
Show/Hide Hidden Text

To write an IF/Else condition follow the steps below:

 

1. From the design section, as mentioned before in "Designing a Workflow," drag the IfElseActivity from the toolbox and place it under an event after which you want to have an IF/Else condition as shown below:

 

window_selectifelseactivity.zoom70
Click on image to magnify/shrink

 

2. Click on ifElseActivity1 and provide the Name, Description, and value for Enabled from the Properties window.

 

ifelse prop.zoom70
Click on image to magnify/shrink

 

3. Click on the left hand side of the "IfElse" branch activity as shown below by an arrow and select "Declarative Rule Condition" or "Code Condition" for the Condition Field under the Properties window.

 

window_selectcondition_ifelse.zoom70
Click on image to magnify/shrink

 

For "Declarative Rule Condition":

 

1. Expand the "Condition" tree in the Properties window and provide a "ConditionName" by clicking on the button as shown below by an arrow:

 

property_conditionname

 

2. The Select Condition dialog box will open. Click on New option.

 

3. The Rule Condition Editor dialog box will open, type in the Condition and click on OK button.

 

window_ruleconditioneditor.zoom85
Click on image to magnify/shrink

 

Note:

The word that is highlighted in the above image in the "Rule Condition Editor" can be a Profile Field of the current Document Type or it can be a PaperSave Variable.

 

4. Drag any of the State Activity under that Condition as shown below:

 

window_dragpsevent.zoom75

Click on image to view magnify and shrink print screen.

 

5. Repeat steps 5 and 6 for the ifElse condition.

 

If "Code Condition" is selected as the Condition Type, then you need to write the code you want to be evaluated in the Condition box and then add a State Activity under that condition.

 

code condition

 

You can also use the profile fields by using the following syntax:

profile.profilefieldname

 

Example:

if(profile.number_textbox > 0)

{

  profile.date_datebox = '12/12/2012';

}

else

{

  profile.date_datebox = '11/11/2011';

}