Tree control: The "Tree Changed" event executes multiple times

  • 16 February 2021
  • 0 replies
  • 19 views

Userlevel 5
Badge +20
 

Tree control: The "Tree is Changed" event executes multiple times

KBS100103

PRODUCT
K2 Five 5.0
K2 smartforms 4.7
BASED ON
K2 Five 5.0
TAGS
SmartForms Designer
Controls
SmartForms
This article was created in response to a support issue logged with K2. The content may include typographical errors and may be revised at any time without notice. This article is not considered official documentation for K2 software and is provided "as is" with no warranties.

Issue

If you configured a message to show when a node in a tree control is clicked, you may see the rule execute multiple times:

 

Image

Symptoms

Your rule may be configured as follows within your Tree control when the issue occurs.

 

Image

 

The issue will occur when you click on the Parent or Child nodes.

Resolution

The developers have confirmed that this is an issue with the product, and they have provided a workaround for the issue.

 

On the Tree Control property, set the Load Ahead Level property to 2:

 

Image

 

Configure an advanced condition on the Tree is Changed Event, that checks whether the selected value is empty or not, only showing the message box, if it’s not empty:

 

Image

 

The result of this is that only one message box is displayed when selecting items.


0 replies

Be the first to reply!

Reply