On demand calculations
You can add a button to a window that provides the result of a calculation without committing the value to the database. This is particularly useful if you have a field on a window that is determined using a scheduled calculation, and you want to be able to see what the value would be if the scheduled calculation were to run now.
To enable on demand calculations:
- In Window Manager, open the window that includes the calculated attribute.
- Expand the Controls tree.
- Add a Button control to the window, and place it next to the calculated field.
- Expand the Attributes tree.
- Select the button control, then in the Property grid, set Is calculate on demand to True.
The button changes to a calculator icon. - In the Calculation Attribute list, select the attribute that you want to be calculated when the analyst clicks the button, then click .
The window is saved.
When an analyst clicks on the window, a message box appears showing what the value of the attribute would be if the calculation were run.