Dynamically Changing Number of Questions

More
1 week 4 days ago #177741 by vevasudevan
vevasudevan created the topic: Dynamically Changing Number of Questions
I have a question about changing the number of questions based on a users input. Specifically, say a user answers 5 to a question, how would i then display 5 input boxes for the user to enter their input into.

Example:

Q How many cars do you have?

User enters 2

What is the brand of car 1?
What is the brand of car 2?



Example 2:
Q How many cars do you have?

User enters 4

What is the brand of car 1?
What is the brand of car 2?
What is the brand of car 3?
What is the brand of car 4?

Please Log in or Create an account to join the conversation.

More
1 week 3 days ago #177743 by tpartner
tpartner replied the topic: Dynamically Changing Number of Questions
Use a multiple-short text with sub-question relevance.

- manual.limesurvey.org/Adding_answers_or_...fic_for_subquestions

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Please Log in or Create an account to join the conversation.

More
1 week 3 days ago #177744 by vevasudevan
vevasudevan replied the topic: Dynamically Changing Number of Questions
Yep, i've tried that but the real functionality I was wondering about was if i could change the amount of sub questions that was asked based on the user input. For example if a user enters 5 then 5 sub questions would be generated and if they say 2 then two sub questions would be generated.

Please Log in or Create an account to join the conversation.

More
1 week 3 days ago #177767 by holch
holch replied the topic: Dynamically Changing Number of Questions
Exactly as Tpartner describes. You need to create a certain number of subquestions and hide/show them via subquestion relevance, based on the number of questions they enter.

There is no way to dynamically add subquestions. You need to create them first and hide/show them according to need.

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Please Log in or Create an account to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now
Join our Newsletter!