Calculate users score and redirect them to custom Thank You Page

  • trainmed2
    Asked on July 9, 2024 at 7:06 PM
    how to calculate the form results for a single questions and how to get the total value for the sum of the questions?
  • trainmed2
    Replied on July 9, 2024 at 11:55 PM

    Hi Sim,

    I mean the results for a single participant. At the end of t he analysis there are 3 results from which the conclusion of the form will be taken.

    Please fill the form below to see the end results of the servery I mean.


    https://survey.fundacionmapfre.org/index.php/211124?lang=en

    Best regards

    Muaz Galal


  • Sim JotForm Support
    Replied on July 11, 2024 at 2:00 AM

    Hi Muaz,

    This is going to be achievable by converting the form to a quiz. Let me show you how to do it:

    1.  Go to the link here.
    2. Click on Open Quiz Form.
    3. Select Allow in the permission window.
    4. In the next window, select the form and click on continue. Calculate users score and redirect them to custom Thank You Page Image 1 Screenshot 70
    5.  Select how you want to show the quiz results from the option.
    6.  In the question, select the correct answer.
    7.  Finally, click on Save Quiz. Calculate users score and redirect them to custom Thank You Page Image 2 Screenshot 81

    Calculate users score and redirect them to custom Thank You Page Image 3 Screenshot 92

    Now for the first question On how to get the value of the sum of the questions, it's achievable by adding a form calculation widget. Let me show you how to do it:

    1. Click on add form element in the upper left corner.Calculate users score and redirect them to custom Thank You Page Image 4 Screenshot 103
    2. Click on the form calculation widget and add it to the form.Calculate users score and redirect them to custom Thank You Page Image 5 Screenshot 114
    3. Click on the wand Icon on the widget.
    4. Set the calculation since your fields already have value in them, you just need to add it to calculation widget itself.Calculate users score and redirect them to custom Thank You Page Image 6 Screenshot 125

    I've made a sample form here so that you can also test it out.

    (B for Question 1, B for Question 2, B for Question 3, A for Question 4, and C for Question 5)

    Keep us updated and let us know if you need any more help.

  • trainmed2
    Replied on July 19, 2024 at 3:08 PM

    Dear Sim,

    Thanks a lot,

    What about the questions that doesn't take yes or no for an answer.

    such like:


    Question1: How many restaurant or take-out meals did you eat the last week?

    Answer: from 0 to 10 meals


    Question2: What is the average daily number of fruit you ate last week?

    Answer: from 0 to 10 fruits


    Best regards

    Muaz Galal

  • trainmed2
    Replied on July 19, 2024 at 3:50 PM


    More details:

    Question1: How many restaurant or take-out meals did you eat the last week?

    Answer: from 0 to 10 meals

    (Add one point if you eat fewer than four meals at a take-out restaurant)


    Question2: What is the average daily number of fruit you ate last week?

    Answer: from 0 to 10 fruits

    (Add two points if you eat two or more fruit daily)

    (Add one point only if one fruit is eaten daily)


    I will appreciate if you answered ASAP


    Best regards

    Muaz Galal

  • Haseeb JotForm Support
    Replied on July 19, 2024 at 5:25 PM

    Hi trainmed2,

    I’ll need a bit of time to look into this. I’ll get back to you as soon as I can.

    Thanks for your patience, we appreciate it.

  • trainmed2
    Replied on July 19, 2024 at 6:56 PM

    Hi Haseeb,

    Thanks, that is OK

    Best regards

    Muaz Galal

  • Haseeb JotForm Support
    Replied on July 20, 2024 at 3:39 PM

    Hi trainmed2,

    Can you please check this form and let us know if this is what you are looking for? So we can share steps by step instructions on how you can create a form like this. Here is also a screencast of how it will work: Calculate users score and redirect them to custom Thank You Page Image 1 Screenshot 20

    You can also check our guide on how to clone a form.

    Once we hear back from them, we'll be able to move forward with this.

  • trainmed2
    Replied on July 21, 2024 at 3:10 AM

    Hi Haseeb,

    Yes it is. Thanks for the help

    Best regards

    Muaz Galal

  • trainmed2
    Replied on July 21, 2024 at 3:27 AM

     Please, share the steps

    And also share how to calculate the total sum of the result by adding the the 2 different types of questions

    Best regards
    Muaz Galal

  • Chris_L JotForm Support
    Replied on July 21, 2024 at 3:33 AM

    Hi Muaz,

    We need more information about your requirement. In your earlier reply, you mentioned there are 3 results. Did you mean you will display a custom message based on the result got by the user? If so, can you share what's the category? For example, out of 100, the user got a score of 35, what's their category?

    Please explain what are the categories and a score requirement to be able to reach that category.

    Once we hear back from you, we'll be able to help you with this.

  • trainmed2
    Replied on July 21, 2024 at 4:54 AM

    Hi Chris_L,

    Thanks for the reply.

    After calculating, there are 4 types of results:

    Below average 0-20:

    This is a good time to work with your provider to help you adopt habits that will significantly improve your health.


    Average 21-30:

    You have some great healthy habits, although there is a great opportunity to improve your health and reduce your risk of disease.


    Very good 31-40:

    You have many healthy habits, although there are some areas where you should evaluate your habits to see if you can improve.


    Excellent 41-50:

    You're in great shape, although there are some minor lifestyle adjustments you can make that will improve your overall health.


    Best regards

    Muaz Galal

  • trainmed2
    Replied on July 21, 2024 at 5:04 AM

    this is the exact survey I am copying:

    Please go through to have an idea

    https://survey.fundacionmapfre.org/index.php/211124?lang=en


    Best regards

    Muaz Galal

  • Mary JotForm Support
    Replied on July 21, 2024 at 5:42 AM

    Hi Muaz,

    Do you want to show the Thank You page conditionally based on the scores? If yes, you can create similar conditions below:

    Below average 0-20:Calculate users score and redirect them to custom Thank You Page Image 1 Screenshot 50

    Average 21-30:

    Calculate users score and redirect them to custom Thank You Page Image 2 Screenshot 61

    Very good 31-40:

    Calculate users score and redirect them to custom Thank You Page Image 3 Screenshot 72

    Excellent 41-50:

    Calculate users score and redirect them to custom Thank You Page Image 4 Screenshot 83

    Give it a try and let us know if this works for you.

  • trainmed2
    Replied on July 21, 2024 at 6:08 AM

    Thanks Mary,

    This will work at the end fore scores, but how can I set the value for a question that doesnt take no or yes as an answer. Like this questions:

    Question1: How many restaurant or take-out meals did you eat the last week?

    Answer: from 0 to 10 meals

    (Add 1 point if you eat fewer than 4 meals at a take-out restaurant)

    ----

    Question2: What is the average daily number of fruit you ate last week?

    Answer: from 0 to 10 fruits

    (Add 2 points if you eat 2 or more fruit daily)

    (Add 1 point only if 1 fruit is eaten daily)

    How can I set the conditions for such questions?

    Best regards

    Muaz Galal

  • trainmed2
    Replied on July 21, 2024 at 6:13 AM

    Question1: How many restaurant or take-out meals did you eat the last week?

    Answer: from 0 to 10 meals

    How I score the result value: (Add 1 point if you eat fewer than 4 meals at a take-out restaurant)

  • Mike_G JotForm Support
    Replied on July 21, 2024 at 6:43 AM

    Hi Muaz,

    I understand what you want to do with your form, but I’ll need a bit of time to look into this. I’ll get back to you as soon as I can.

    Thanks for your patience, we appreciate it.

  • trainmed2
    Replied on July 21, 2024 at 7:03 AM

    Hi Mike_G,

    Thanks a lot. I Will be waiting


    Best regards

    Muaz Galal

  • Mike_G JotForm Support
    Replied on July 22, 2024 at 6:39 AM

    Hi Muaz,

    Since the values of the options in questions #1 and #2 in your example are going to be needed among other field questions to calculate a total score, we will be using the Calculation Values feature to assign different values for those fields' options. Suppose you have already set up the following dropdown fields on your form:

    • How many restaurant or take-out meals did you eat the last week?
    • What is the average daily number of fruit you ate last week?

    Let me show you how to set up the calculation values for their options:

    1. In Form Builder, select the How many restaurant or take-out meals did you eat the last week? dropdown field and click on the Gear icon to open its Properties.
    2. Go to the Options tab and toggle the Calculation Values to the On position.
    3. In the box at the right of the field options, enter 1 for those below 4:
      Calculate users score and redirect them to custom Thank You Page Image 1 Screenshot 70

    Repeat the same steps above for the What is the average daily number of fruit you ate last week? dropdown field but this time, enter 0 for the 0 option, 1 for the 1 option, and 2 for the rest of the options.

    Calculate users score and redirect them to custom Thank You Page Image 2 Screenshot 81

    Next, we will use a Form Calculation widget to calculate the score. Let me show you how:

    1. In Form Builder, click on the Add Form Elements menu on the left side of the page.
    2. Under the Widgets tab, search for Form Calculation and drag and drop it into the form.
    3. Click on the Wand icon on the right of the Form Calculation to open the Widget Settings if it does not open automatically after adding the widget to the form.
    4. In the Widget Settings, use the Numpad on the right to add numbers, operators, parenthesis, decimal point, and math functions to the formula.
    5. Click on Add Field above it to add fields on the form to the formula.
      Calculate users score and redirect them to custom Thank You Page Image 3 Screenshot 92
    6. Enter the formula below and click on Save at the bottom of the Widget Settings:
      Calculate users score and redirect them to custom Thank You Page Image 4 Screenshot 103
    7. After that, click on the Gear icon on the right of the widget to open its Properties.
    8. Go to the Advanced tab, and enter Total Score in the Field Label.
      Calculate users score and redirect them to custom Thank You Page Image 5 Screenshot 114

    Check out the screencast below to see the result:

    Calculate users score and redirect them to custom Thank You Page Image 6 Screenshot 125

    You can test my Demo Form here, and this guide will explain how to clone it to your account if you want to inspect it.

    Give it a try, and reach out again if you have any other questions.

  • trainmed2
    Replied on July 22, 2024 at 3:02 PM

    Dear Mike_G,

    Thanks a lot for your great help. I will follow your guide and get back to you


    Best regards

    Muaz Galal

  • trainmed2
    Replied on July 24, 2024 at 3:22 PM

    Hi Mike_G,

    I have an issues:

    the total score should be between 20 to 50 pints, but the value comes in a very big number

    (Total score = 10022151000)

    can you please look at the original survey and advice

    https://www.jotform.com/build/242055961156457


    Best regards

    Muaz Galal

  • Haseeb JotForm Support
    Replied on July 24, 2024 at 4:28 PM

    Hi Muaz,

    I have checked your form, and you have 10 questions in total and each question has maximum of 10 points, so the total score should be 10-100. I also checked the calculation, and you forgot to add the + sign between the form fields. Here is the screenshot: Calculate users score and redirect them to custom Thank You Page Image 1 Screenshot 40

    You need to add + sign between the fields, it is easy. Let's do it.

    1. In the form builder, click on the magic wand icon for the Total Score.
    2. Now. Add + sign after each form field except for the last one.
    3. Click on Green Save button. Calculate users score and redirect them to custom Thank You Page Image 2 Screenshot 51

    Here are the results now: Calculate users score and redirect them to custom Thank You Page Image 3 Screenshot 62 Keep us updated and let us know if you need any more help.

  • trainmed2
    Replied on July 24, 2024 at 7:16 PM

    Hi Haseeb,

    Thanks a lot for your help, I have added the rest of the questions to the calculation, but I couldn't add the + icon as it is not properly aligning near the fields.

    can you please check again

    And can you please check if the conditions I made for some questions is well done?


    Best regards

    Muaz Galal

  • Mary JotForm Support
    Replied on July 24, 2024 at 10:37 PM

    Hi Muaz,

    You need to click on the space right after the form field in your calculation widget to enter the plus sign:

    Calculate users score and redirect them to custom Thank You Page Image 1 Screenshot 40

    AS for your conditions, you need to add another IF condition when displaying your Thank You message. Currently, it looks like this:

    Calculate users score and redirect them to custom Thank You Page Image 2 Screenshot 51

    It should look like this:

    Calculate users score and redirect them to custom Thank You Page Image 3 Screenshot 62

    Give it a try and let us know if you have any other questions.

  • trainmed2
    Replied on July 25, 2024 at 2:01 AM

    Hi Mary,

    Thanks a lot for your guide. I will follow it.


    Best regards

    Muaz Galal

  • trainmed2
    Replied on July 25, 2024 at 9:15 AM


    I tried to ad + but it is not aligned, please check the photoCalculate users score and redirect them to custom Thank You Page Image 1 Screenshot 20

  • Cristy JotForm Support
    Replied on July 25, 2024 at 10:02 AM

    Hi Muaz,

    I looked at the screenshot you provided, but I'm not entirely sure what you mean by the + sign not being aligned. Are you referring to the alignment of the + symbol in the Form Calculation Widget, or is there another part of the form you're concerned about? The alignment should not cause any issues. It appears this way because all the other elements do not have the same measurements, so the alignment adjusts automatically. As long as you place the + sign between each equation, the formula should work correctly and calculate the total value.

    I also noticed in the screenshot that you haven't added the + sign between all the fields. Make sure to add the + sign between each field to ensure the formula works as intended. If this isn't exactly what you're concerned about or if you're trying to achieve something else, can you explain a bit more so I can get a better idea and assist you better?

    Give it a try and let us know how it goes.

  • trainmed2
    Replied on July 25, 2024 at 11:02 AM

    Hi Cristy,

    Thanks, it worked

    As for the conditional results, can you please check?

    I tried to follow Mary's advice but didn't figure how

    but I need the maximum total score to be 50 points! how can I do it? I need the results to be:


    Below average 0-20: (conditional massage)

    Average 21-30: (conditional massage)

    Very good 31-40: (conditional massage)

    Excellent 41-50: (conditional massage)


    I am really appreciative of your help

    Best regards

    Muaz Galal

  • Ibrar JotForm Support
    Replied on July 25, 2024 at 11:40 AM

    Hi Muaz,

    I've reviewed your form and found you have added Scale Rating elements on it. Since, we can't assign calculation values to Scale Rating element. As an alternative, I suggest you to either divide each scale rating element with 10 or you can sum up all Scale Rating elements and then divide by 10. Let me show you how:

    • In Form builder, select Form Calculation widget and Wand icon.

    Calculate users score and redirect them to custom Thank You Page Image 1 Screenshot 40

    • Set the formula as below picture & click on Save button.

    Calculate users score and redirect them to custom Thank You Page Image 2 Screenshot 51

    Result

    Calculate users score and redirect them to custom Thank You Page Image 3 Screenshot 62

    You can also check out the demo form and if you want to clone the demo form, you can easily clone it. This guide will help you to do that.

    Give it a try and reach out again if you have any other questions.

  • trainmed2
    Replied on July 25, 2024 at 5:15 PM

    Thanks Ibrar,

    I divided the all the scale Rating elements by 10, but the to total score still goes up to :250

    I need the maximum to be 50

    attached is the original survey so you can see the big picture

    Calculate users score and redirect them to custom Thank You Page Image 1 Screenshot 30Calculate users score and redirect them to custom Thank You Page Image 2 Screenshot 41

    Best regards

    Muaz Galal


  • Joseph Christian JotForm Support
    Replied on July 25, 2024 at 8:00 PM

    Hi Muaz,

    I’ll need a bit of time to look into this. I’ll get back to you as soon as I can.

    Thanks for your patience, we appreciate it.


  • Joseph Christian JotForm Support
    Replied on July 25, 2024 at 8:23 PM

    Hi Muaz,

    If I understood correctly, you want to calculate a total score based on values from 10 Single Choice fields, 10 Scale Rating fields, and a Dropdown field, and then adjust this score to a maximum of 50. To combine the scores from all these fields and adjust them to a maximum of 50, you will first need to sum up the scores from each type of element separately and then combine them. Here's how to do it: 

    1. First, to calculate the score for Single Choice Fields, let's add the first Form Calculation widget. I noticed in your calculation values, each Yes option is worth 2 points and No is worth 0 points. 

    • In Form Builder, click on Add Form Element on the left side of the page.
    • Under the Widgets tab, search for Form Calculation widget and add it to your form.

    Calculate users score and redirect them to custom Thank You Page Image 1 Screenshot 120Set the formula like you see below to calculate the total score for 10 Single Choice fields.

    Calculate users score and redirect them to custom Thank You Page Image 2 Screenshot 1312. Next, to calculate the score for Scale Rating Fields, let's add the second Form Calculation widget.

    Calculate users score and redirect them to custom Thank You Page Image 3 Screenshot 142Set the calculations as follows to calculate the Scale Rating total score:

    Calculate users score and redirect them to custom Thank You Page Image 4 Screenshot 1533. Then, let's add the third Form Calculation widget to get the score from the Dropdown field.

    Calculate users score and redirect them to custom Thank You Page Image 5 Screenshot 164Set the calculations as follows to get the score from the Dropdown field:

    Calculate users score and redirect them to custom Thank You Page Image 6 Screenshot 1754. Now let's add the 4th Form Calculation widget to combine the scores from all elements.

    Calculate users score and redirect them to custom Thank You Page Image 7 Screenshot 186 Set the calculations as follows to add up the scores from all elements:

    Calculate users score and redirect them to custom Thank You Page Image 8 Screenshot 1975. Lastly, let's add the last Form Calculation Widget to adjust the combined score to a maximum of 50.

    Calculate users score and redirect them to custom Thank You Page Image 9 Screenshot 208The highest possible combined score is 127 (22 from Single Choice fields, 100 from Scale Rating fields, and 5 from the Dropdown field). Use the following formula to normalize the combined score to fit within a range of 0 to 50:

    Calculate users score and redirect them to custom Thank You Page Image 10 Screenshot 219That's it. Checkout my screencast below to see my results:

    Calculate users score and redirect them to custom Thank You Page Image 11 Screenshot 2210 You can clone my demo form here to see how the Form Calculation widgets are set up.

    Let us know if you have any other questions.

  • trainmed2
    Replied on July 26, 2024 at 6:28 AM

    Joseph Christian, you are a genius!

    last, I need to set the thank you massage to show one of the following results:

    Below average
    0-20: (conditional massage)

    Average
    21-30: (conditional massage)

    Very good
    31-40: (conditional massage)

    Excellent
    41-50: (conditional massage)


    I am can't thank you enough

    Best regards

    Muaz Galal

  • Lorenz JotForm Support
    Replied on July 26, 2024 at 7:17 AM

    Hi Muaz,

    I've moved your question to a new thread, to avoid confusion and for us to assist you better. You can wait for our response here.

    Thanks for your understanding, we appreciate it.

Your Answer