How can I conditionally display a different message based on the answers provided by the respondent?

  • coachkclear
    Asked on April 10, 2019 at 12:40 PM
  • David JotForm Support
    Replied on April 10, 2019 at 1:55 PM

    It seems the rest of your question might not have come through.  Let us know what we can help with in regards to the form you referenced and we will follow up as soon as we can.

  • coachkclear
    Replied on April 10, 2019 at 2:43 PM
    I would like to have a page at the end of my form that adds up the "Yes"
    answers and then shows this:
    *If total "yes" count = 1-4*
    Chances are, many of the questions made you think about the legacy you
    would leave if something
    happened to you. Now, you may be more aware of the need to be sure your
    loved ones are taken care
    of when you are gone. Buying your first or an additional life insurance
    policy is a great way to protect
    your family.
    *If total "yes" count = 5-8*
    You may currently have some life insurance but may be concerned that it
    might not stretch as far as
    you would like. You want to be sure your family is able to remain in their
    home and live the lifestyle
    they were used to. The less change at a hard time like this, the better.
    Right now is a great time to take
    another look at your life insurance coverage. There may be just the right
    policy that can give you that
    additional peace of mind.
    *If total "yes" count = 9-12*
    Congratulations! You have made great strides towards protecting your family
    in the event something
    happens to you. There is a good chance your family will be able to grieve
    without the burden of
    struggling to meet final expenses. Along with protecting your family, it is
    a good idea to consider future
    earning potential. Purchasing additional coverage later in life can be
    difficult and/or expensive. Consider
    purchasing additional insurance now. Whether you’re just starting to think
    about your legacy or building
    ...
  • Support_Management Jotform Support
    Replied on April 10, 2019 at 5:03 PM

    Hey @coachkclear - Can you tell us how you want to implement this? I understand that your goal is to display different messages based on the score (where the score is based from the number of yeses).

    If you want the messages to appear before submission, you can add multiple TEXT FIELDS to your form. Each text field should correspond with the messages you outlined.

    For example:

    How can I conditionally display a different message based on the answers provided by the respondent? Image 1 Screenshot 50

    Afterwards, you will conditionally show them based on the score.

    I can see you already assigned CALCULATION VALUES to your SINGLE CHOICE fields so you're on the right track. The next step is to tally the total. Although you have a FORM CALCULATION WIDGET in place, your formula seems to be off.

    How can I conditionally display a different message based on the answers provided by the respondent? Image 2 Screenshot 61

    Make sure that your formula is mathematically correct and that all fields added have a black background like so:

    How can I conditionally display a different message based on the answers provided by the respondent? Image 3 Screenshot 72

    To conditionally display the TEXT FIELDS you added, set up a condition that matches the ranges you described:

    How can I conditionally display a different message based on the answers provided by the respondent? Image 4 Screenshot 83

    The condition above goes like this:

    IF Total Yes IS GREATER THAN 0 AND LESS THAN 5, THEN SHOW the corresponding text field.

    Repeat this process for the remaining conditions. The IF ALL above denotes that both conditions should be met (thus matching your requirement of a score of 1 to 4).

    Complete guide: How-to-Show-or-Hide-Fields-Base-on-User-s-Answer

    Otherwise, if you intend to show these messages after submission, then you can conditionally set up multiple thank you messages.

    Complete guide: How-to-Change-Thank-You-Message-Using-Conditional-Logic

  • coachkclear
    Replied on April 10, 2019 at 5:43 PM
    I just want a simple end screen that tallys up the yes answers and shows it
    at the end along with all the other text I sent. I don't need it to show
    three different end screens base off their answers, 1 is fine.
    ...
  • Support_Management Jotform Support
    Replied on April 10, 2019 at 7:20 PM

    I don't need it to show three different end screens base off their answers, 1 is fine.

    My suggestions earlier will only show one message. Regardless if you pick the TEXT FIELD or the THANK YOU MESSAGE route, both ways will only conditionally show a single end message. Since you still haven't confirmed whether you want the message to be shown before or after submission, I'll just create a cloned copy of your form using text fields. This would mean that your respondents will see the message right before submitting the form.

    https://www.jotform.com/90996913457978/

    Test it out by making choices that will meet the conditions you described. Feel free to clone the form if you wish to use this inside your account.

    Complete guide: How-to-Clone-an-Existing-Form-from-a-URL