Known Issue: Only Top Subview/Form is Closed with Synchronous Rule
KB001784
PRODUCT
Issue
When more than one subview/form is closed using synchronously (then) rules without any user interaction, the expected behavior might differ from previous releases. This behavior change is due to functionality changes made in K2 4.7 where, if there is no user interaction between the different closing actions, only the top subview/form is closed. The subsequent closing actions are not executed.
Workaround
Instead of closing the subviews/forms synchronously, use the asynchronously execution type to close the second subview/form.
Example
Below is an example of a scenario that behaves differently to previous versions.
In the image below, rules are set up to open Form1 when the button is clicked on MainForm, and open View1 when the button is clicked on Form1.
To close View1, a rule is created to transfer data to Form1 when the button on View1 is clicked, then close View1. Once the field on Form1 is changed, a rule is set up to close Form1 as well.
The set up for the closing of Form1 is as follows:
With previous releases this behaves as expected where View1 is closed and then Form1 is closed. However, with the changes in functionality and using a transfer data action with an onchange event, the onchange event executes before the rest of the actions execute causing only View1 to close. To remedy this issue, change the execution type of the second close action to asynchronously instead of synchronously (then).