How to recalculate values in controls dynamically after a user changes some values

Sometimes it may be necessary to dynamically recalculate values in controls of a form after a user has changed values in other controls. For example, let’s say we have a form of the object “MyObject” showing 3 attributes – “Value1”, “Value2” and “Sum”. We want to dynamically show the value of the attribute Sum as Value1 + Value2. We want the system to show the sum immediately after the user changes the values of Value1 or Value2. To do this we need to define a business rule:

MyObject.Sum = MyObject.Value1 + MyObject.Value2 

This is not different from any other business rule. The trick here is when defining the rule to go to the “Advanced” tab and tick the “Use rule in dynamic recalculation on forms” checkbox. If this is ticked Aware IM will automatically fire the rule when any field that the rule depends on loses focus, and display the result.

  • Last modified: 2023/05/09 02:01