Activities
latest
false
If - Other latest
Banner background image
logo
Workflow Activities
Last updated Feb 23, 2024

If

System.Activities.Statements.If

Enables your project to take one of two different courses of action, depending on whether a specified condition is met. This activity contains a Condition, a Then branch, and an optional Else branch. The Condition field must contain a Boolean expression according to which either the Then or the Else branch is executed. The Then branch comprises the activities to be performed if the condition is true. The optional Else branch comprises the activities to be performed if the condition is false. To display the Else branch, click Show Else in the body of the activity.

For more complex scenarios, you can use the Else If activity.

To learn how to use this activity, see:

Project compatibility

Windows | Windows - Legacy | Cross-Platform

Windows and Cross-Platform Configuration

  • Condition - The condition to evaluate which activity to execute.
  • Then - The activity to execute in case the condition is true, add it using the plus icon, or drag and drop it here.
  • Else - The activity to execute in case the condition is false, add it using the plus icon, or drag and drop it here.

Windows - Legacy Configuration

From the activity body
  • Condition - The condition to evaluate which activity to execute.
  • Then - The activity to execute in case the condition is true, add it using the plus icon, or drag and drop it here.
  • Else - The activity to execute in case the condition is false, add it using the plus icon, or drag and drop it here.
From the properties panel

Common

  • DisplayName - The name displayed for the activity in the Designer panel.

Misc

  • Condition - The condition to evaluate which activity to execute.
  • Private - If selected, the data used in the activity is not logged.

This activity is built by Microsoft. For more information, see the official Microsoft documentation.

Support and Services icon
Get The Help You Need
UiPath Academy icon
Learning RPA - Automation Courses
UiPath Forum icon
UiPath Community Forum
Uipath Logo White
Trust and Security
© 2005-2024 UiPath. All rights reserved.