Answered

Need help using outcome quiz based on variable values

  • 22 June 2023
  • 6 replies
  • 115 views

Hey there, brand new to TypeForm and I’m sure theres a way to accomplish what I’m after I just can’t figure it out. 

Essentially I need to be able to direct to a specific ending page based on both answers to specific questions, AND numeric values of variables I’ve created. 

For example One question would be “Are you okay with opening a credit card that has an annual fee” -- obviously thats an easy yes or no. 

But another question would be “how many cards have you opened in the last 24 months?” where they would enter a number.

 

I want to be able to say IF they answered yes, AND the numeric value they entered on question 2 was “less than 5”, than send them to ending page A. etc. 

 

Later on I also want to be able to incorporate a custom variable I’ve created which is essentially the SUM of numerical answers from about 7 questions. I set up each question to add the value of answer given to the variable count. But I can’t find a way to incorporate that variable into my ending page logic?

Hopefully I’m using the right terminology, my apologies if not. I’ve scoured the articles and I feel like I haven’t been able to find an answer.

Thanks in advance for the help! 

icon

Best answer by john.desborough 22 June 2023, 19:40

View original

6 replies

Userlevel 7
Badge +5

Hi @mtborsic Welcome to Typeform! Happy to have you here. 

On the very last question, you’d essentially want to set up a logic jump that looks something like this: 

You’d change the numbers accordingly but essentially, you’ll need to put in every possible option and its ending on the last question people will answer in order to lead them to the correct ending. 

Okay I think that makes sense. So it has to be it’s own question? 

Basically I have about 7 questions that all ask about about how much the user spends in a given month in a specific category (Groceries, Gas, Utilities, etc.) I then have an @spend variable setup to add all of these answers together. I want to direct to an ending based on THAT number…

If I’m understanding correctly I’m hearing that there really isn’t a way to do this without having the user enter that number on the very last question? 

Thanks so much for your help! 

Userlevel 7
Badge +6

@mtborsic - if you have a variable set up to capture the sum of the numeric answers, you can use logic at each question to add the input value from the user to the variable … something like this

  • if q2 greater than 0 then add q2 to v_sum
  • if q3 greater than 0 then add q3 to v_um
  • etc

that way you have a running total of the entire set of values to display and/or use in future calculations.. as well as drive your routing logic:

  • if v_sum less than 1000 then go to A
  • if v_sum is greater than or equal to 1000 and v_sum is less than 5000 then go to B
  • etc.. 

hope that help moves the needle

 

des

@john.desborough This definitely helps! I believe the first part of this is what I already have setup. The part I am struggling with is part B of what you explained. 

How/where do I create the part of the logic that says “if V_sum is less than 1000 then go to A”? This is the part I can’t seem to figure out. Do I need to create a visible question for that?

Also if there are any screenshots or anything that would be helpful for me to share with you I’m happy to! 

 

Thanks again

Userlevel 7
Badge +6

@mtborsic - that would be created using logic rules.. just create those rules on the last question page before you want to send them to an ending… then, on submit, they will be routed to the appropriate.. 

 

des

@john.desborough I guess my problem is when I create that rule in the logic section, on the final “go-to” I cannot choose an ending screen. 

And If I try to do it via the quiz & outcome section, I can’t choose a variable value as an “answer” that determines the ending. This is the spot I’m stuck.

Reply