​​How to update all values of a control inside a repeater based on another control value outside the repeater?

Last Update: February 02, 2018

Here are the steps on how to do that.

  1. Open the form in design mode.
  2. Add Repeater control to the form workspace and set its ID property to repeater1.
  3. Add TextBox control inside repeater1 and set its ID property to txtTextbox1
  4. Add TextBox control outside repeater1 and set its ID property to txtTextbox2.
  5. ​Select txtTextbox2
  6. In the Rules pane, click on the Add icon to add a new rule, the Rule Manager dialog will open.
    How to auto-shifting Panel control in a form2.jpg
  7. Add a new rule as follows:
    A. Change the Rule Name as desired.
    B. Change the Rule Type to Action.
    C. Change the Event Type to onChange. Check "Execute if event triggered only on this control".
    D. In the Action section, type the following script:
        setValueOfControlInRepeater(txtTextbox1,txtTextbox2) //This will update all values of txtTextbox1 inside the repeater.
    E. Click on the Save button to save the rule.
    Note: You can use Assistance Panel to help you adding functions and related parameters, form variables and form controls to Conditions and/or Actions sections.
  8. Test the form by clicking on the Preview button in the View Group.