Form Calculation Widget: Why did it suddenly stop calculating?

  • LBtaekwondo
    Asked on December 21, 2016 at 3:36 PM

    Was working 3 days ago - Submission on 12/18/16 calculated correctly, but submissions since then are all calculating to 0. We have not changed anything since then as far as I know. I would appreciate any help/advice. Thanks!

  • Kevin Support Team Lead
    Replied on December 21, 2016 at 5:59 PM

    I have checked your form and it took me some time to understand how the calculation works, but after spending some time re-doing the calculation and investigating what can be causing the issue I think it is due to some fields that you have in your form, for example, you have this in your calculation: 

    Form Calculation Widget: Why did it suddenly stop calculating? Image 1 Screenshot 40

    Do note that if some of the fields is  empty this will affect the entire calculation, on my end I have to redo the calculation and found this, please see the screen-cast below: 

    Form Calculation Widget: Why did it suddenly stop calculating? Image 2 Screenshot 51

    Since your drop downs are not required they may be empty, in the script that works the calculation an empty value will be taken as not assigned so to resolve this problem I would suggest you to add a 0 to the default or empty selection of your drop downs: 

    Form Calculation Widget: Why did it suddenly stop calculating? Image 3 Screenshot 62

    I made this change on my cloned form of yours, here's the link if you want to take a look: https://www.jotformpro.com/form/63556269833972 

    Please if you have any question, let us know. 

  • LBtaekwondo
    Replied on December 21, 2016 at 8:23 PM

    Thanks! I also found that the calculation did not like the $ I had at the beginning of the calc. It always worked in the past, but for some reason, no longer.

    I appreciate your time...I'm glad to have our form up and running again!