1 Reply Latest reply on Dec 13, 2016 1:41 AM by try67

    Count evaluations

    srolls

      I have an acrobat form with 10 questions that people can evaluate using one of 4 radios (0-1-2-3). I want to count how many of the questions score 2 or greater and put that in the 'TOTAL'.

       

      ie.

       

      1. 1

      2. 2

      3. 0

      4. 3

      5. 3

      6. 3

      7. 2

      8. 1

      9. 2

      10. 3

      TOTAL = 7

        • 1. Re: Count evaluations
          try67 MVP & Adobe Community Professional

          Let's say the fields are called Q1, Q2, ..., Q10. You can use this code as the custom calculation script of the Total field:

           

          var total = 0;
          for (var i=1; i<=10; i++) {
              if (Number(this.getField("Q"+i).valueAsString)>=2) total++;
          }
          event.value = total;