Skip to main content
Nintex Community Menu Bar
Solved

Onchange events on two add/edit fields in an editable list. How to solve?

  • Oct 26, 2026 3:37 PM UTC
  • 1 reply
  • 20 views
  • Translate All

Forum|alt.badge.img

I have two views in a K2 SmartForm (automation on premise), where I need to use onchange event for two add/edit fields, but it get me some issues… 
On the Onchange-events, an advanced smo-object method  gets data from an external api, and fill up the add/edit rows in the view.
On the first onchange-event, it gets data for the field, that also have an onchange-event on itself… → When x is filled in - get y, and the opposite, plus other fields.
The events triggers not only once, but several times, and other errors shows, when both the rules is enabled. Someone that have done anything similiar, and have any solution to the problem/-s?
I get problems with how many times the event triggers, and
I get an error, that I can’t find (can’t convert string to timespan..),which should in some way be related to the events , because it disappears, when I just run one of the onchange- events. 
 The - When the view executed List item added , is triggered when user clicks another row…, and a rule on the form is saving the data to database, on it.

Best answer by ScottCaseIT

If I am understanding correctly, you sort of have a circular reference situation going on where a series of on change events assigned to fields, trigger an API call to update a field in which that has an on-Change event to fill other fields so the two fields are triggering each other in a loop as the contents are chagned.

 

What I have done in similar situations with event triggers, is I will identify some sort of state that can be evaluated with an advanced condition or add a hidden data label for which I can control the value to act as that state, and then use the advanced condition to handle if that on change event should continue with whatever you have configured it to do.

 

The events are going what they are designed to do which is react to changes, so you will need to implement some sort of execution control if you choose to continue with this implementation.

HTH,

Scott

 

View original

1 reply

ScottCaseIT
Nintex Partner
Forum|alt.badge.img+5
  • Nintex Partner
  • Answer
  • Nov 13, 2026 2:33 PM UTC

If I am understanding correctly, you sort of have a circular reference situation going on where a series of on change events assigned to fields, trigger an API call to update a field in which that has an on-Change event to fill other fields so the two fields are triggering each other in a loop as the contents are chagned.

 

What I have done in similar situations with event triggers, is I will identify some sort of state that can be evaluated with an advanced condition or add a hidden data label for which I can control the value to act as that state, and then use the advanced condition to handle if that on change event should continue with whatever you have configured it to do.

 

The events are going what they are designed to do which is react to changes, so you will need to implement some sort of execution control if you choose to continue with this implementation.

HTH,

Scott

 

Translate