Articles → UIPATH → Flow Switch Activity In Uipath

Flow Switch Activity In Uipath






Purpose





Example




  1. Drag and drop the "Input Dialog" activity. The purpose is to get the value from the user. Based on the value entered by the user, we will perform different actions using the "Flow Switch" activity.
  2. Set the output of the "Input Dialog" activity to the string variable "opt".
  3. Picture showing the properties window of the input dialog in UiPath

    Click to Enlarge

  4. Drag and drop the "Flow Switch" activity. Each "Flow Switch" activity contains multiple points or nodes on each side. These points or nodes are visible only when the mouse is hovered over the "Flow Switch" activity.
  5. Picture showing the Flow Switch activity with multiple points

    Click to Enlarge

  6. Attach three message boxes. In the "Flow Switch" activity, an arrow signifies the association.
  7. Picture showing the message box attached to the Flow Switch activity

    Click to Enlarge

  8. Click on the arrow and set the value of the "case" attribute to "A" and "B" for 2 message boxes.
  9. Finally, set the "Expression" attribute of the "Flow Switch" activity to the variable "opt". It means that which message box to invoke depends upon the value of the "opt" variable.
  10. Picture showing the properties of the cases of the Flow Switch activity

    Click to Enlarge

  11. Save and run the bot.

Output


Picture showing the output of the Flow Switch activity

Click to Enlarge


Posted By  -  Karan Gupta
 
Posted On  -  Saturday, February 13, 2021

Query/Feedback


Your Email Id  
 
Subject 
 
Query/FeedbackCharacters remaining 250