I have several arrays that I'm using equations to calculate their score. So let's say I have 3 arrays and the 3 equations, one equation after each array. This part works great! No Problems. But, can I use another equation to add them all up?
For instance the 3 equation fields are array1score, array2score, array3score. Can I have a last equation be the sum of the 3.
Total Score: {sum(array1score.value,array2score.value,array3score.value)}
So far it doesn't work for me. Keeps returning 0 even though each has a number showing. Wondering if the value isn't there until it's written to the database. I've also used the array1score.NAOK and it also didn't work.
I just did a quick test and when i used .value on an array row, it always returned 0. Try using .NAOK, that worked for me.
In my working test I had 1 array and 3 equations. First equation had {array_1.NAOK}, second equation had {array_2.NAOK} and third had {sum(eq1.NAOK,eq2.NAOK)}.
Thanks Bigred. I tried that but so far I feel like I'm just hitting my head against the wall and hoping for a different outcome
I've attached a small sample survey to showcase my lack of understanding of this problem. If anyone can point me in the right direction to the promise land I would be much appreciative.
Set the answer code to the number value you want. Of course we cant set a code to -1, but the if statement above will change a 4 into a -1 when summing your answers.
Also, you have text in your equations making them strings so you final sum wouldn't have worked.
Remove the text and modify the above sum/if statements for your first two equation questions then sum them together in your final equation question.
You Rock! I was putting text in the fields and trying to do calculations with it. In my head I thought it was just saving everything after the colon and the before part was just for show.