activities
latest
false
UiPath logo, featuring letters U and I in white
Workflow Activities
Last updated Nov 18, 2024

Updating form data

This tutorial demonstrates how to change form values at runtime, while the form is showing. You can achieve this using the Continue Workflow Execution feature inside the Show Form activity and using the Set Form Values, and Form Trigger activities. This example demonstrates how to build a form with a counter that can be incremented or decremented by clicking buttons within the form.
  1. (Optional) Create a folder called Counter. This is where you want to store the uiform file and the corresponding trigger workflows.
  2. Create a new form called Counter.uiform and place it inside the Counter folder.
    1. (Optional) Add a Columns component, with three columns that have the following widths: 2, 6, and 2.
    2. Add a Number component inside the middle column, and set the label as counter, and the Default value to 1.
    3. Add two Button components in the other columns, and set the labels as:
      • increase
      • decrease
  3. In the Main.xaml workflow add a Show Formactivity and seelct Counter.uiform
  4. Add a Run Local Triggers activity.
  5. Create a trigger workflow that activates when the user clicks on the increase button.
    1. Add a Form Trigger Activity and select Increase clicked.
    2. Add a Get Form Values activity to retrieve the value of the counter.
    3. Add an Assign activity to and add it by 1.
    4. Add a Set Form Values activity to pass the value back into the form.
  6. Create a trigger workflow that activates when the user clicks on the decrease button.
    1. Add a Form Trigger Activity and select Decrease clicked.
    2. Add a Get Form Values activity to retrieve the value of the counter.
    3. Add an Assign activity to and substract it by 1.
    4. Add a Set Form Values activity to pass the value back into the form.

Workflow example

To follow the steps in this tutorial. see the workflow example.

  • Workflow example

Was this page helpful?

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