cancel
Showing results for 
Search instead for 
Did you mean: 
dleathrum
Nintex Newbie

dateDiffDays always returns zero in Nintex Forms 2013

Jump to solution

Hello,

 

I am trying to have a nintex form which the person fills out a departure and a return date and the form informs the initiator of how many days and nights this is.  The days calculation I am using dateDiffDays with the two fields plus 1.  For nights I simply am using days-1.  However the days does not change from 1, which I'm assuming is coming from the +1.  I have the days calculated value fields set up like this.

 

 

With the look of when I fill out the form looking like this.

 

 

I do not see where I have messed up since the two dates seem to be filled into the correct fields when I submit the form, so it is not a lack of set up there.

 

Thank you,

Duncan Leathrum

0 Kudos
Reply
4 Replies
lakshminarayana
Nintex Newbie

Re: dateDiffDays always returns zero in Nintex Forms 2013

Jump to solution

Hi Duncan Leathrum,

The same settings i am using, it is working fine. May i know which version you are using?

Thanks,

Lakshmi C

0 Kudos
Reply
Automation Master
Automation Master

Re: dateDiffDays always returns zero in Nintex Forms 2013

Jump to solution

are you sure you used named controls in formula and not item properties?

did you by any chance populated value(s) into date controls by javascript?

Reply
dleathrum
Nintex Newbie

Re: dateDiffDays always returns zero in Nintex Forms 2013

Jump to solution

I was using item properties, whoops did not know to use named controls.  Thanks that solved the days calculation!  I did run into another issue though, where I have another issue where for my nights calculation, I am using the formula here,

but my variable of Days in not in the named controls, only the item properties.  I have Days as a column in my list and first initialize it in the calculated value right before nights.  

Reply
dleathrum
Nintex Newbie

Re: dateDiffDays always returns zero in Nintex Forms 2013

Jump to solution

I just switched to using the same formula as days but did not add one.  It works well now.  Thanks!

Reply