Configure Tab Navigation to Optimize Performance

When you add views to tabs, rules are automatically created to initialize the views when the form initializes. When you open the form, you may experience a performance difference as all the initialize actions execute before the form opens. To optimize performance when the form initializes, it is advised to configure the view initialize actions to only execute when a tab is clicked or selected. Follow the steps below to configure this rule:

  1. Create a form with two tabs.
  2. Edit the When the Form is Initializing rule. The rule includes all the view initialize actions as shown below.
  3. Disable all the view initialize and refresh actions as shown below. Save the rule.
  4. Create a new rule for each of the tabs. Add the When a control on the Form raises an event rule event. Select one of the tabs and select the Clicked permutation.
    • Clicked: The rule executes when the tab is clicked.
    • Deselected: The rule executes after click of the next tab. For example Tab 1 is selected, then you click on Tab 2. Tab 2's event executes first and then Tab 1's Deselected event executes.
    • Selected: The rule executes when the selected tab is shown, selected or opened by another rule or action.
  5. Add the Execute a View method action. Select the view and Initialize method. Do this for all the views on that tab, then add the same rule for the other tab.

This example improves performance as views now only initialize when a tab is clicked. When you use tab navigation to reconfiguring the view initialize actions it is important to remember to delete or disable those actions from the form initialize rule.