How to bind on change event to Nintex Form Date and Time control?

  • 25 December 2017
  • 3 replies
  • 35 views

Badge +2

Hello,

I want to bind on change event on Date and Time control of Nintex Form.

I tried to bound it using following code:

var ctrl_TempDateTime = NWF$("#" + ctrlID_TempDateTime);
 if (ctrl_TempDateTime != null) {
 NWF$(ctrl_TempDateTime).datepicker().on("input change", function (e) {
 console.log("Date changed: ", e.target.value);
 });
}

It is being fired when I am changing date portion but it is not being fired when I am changing time portion. 


So how can I bind on change event in date time control in such a way that it should fire when I change time as well.

Any help will be appreciated.


3 replies

Badge +6

I suppose, the datepicker is a jQuery UI widget, so try handling these events:

Badge +2

Hi Alexey,

I have already tried but not worked.

Also above method will work only for Date Picker i.e. when date is being changed. It will not fire change event when time portion i.e. two drop down values will be changes.

Userlevel 5
Badge +14

yeah, you need to attach your own onchange handler to each of single datepicker controls.

have a look on this - https://community.nintex.com/thread/10872#comment-34952 

Reply