Do not allow answers based on previous answers

More
2 years 9 months ago #111741 by andogro
andogro created the topic: Do not allow answers based on previous answers
Hello
I am creating a survey where some questions have answers that should not be allowed based on previous ones. For example:

A. How many close friends do you have
1. 0
2. 1
3. 2
4. 3-5
5. 6-10
6. More than 10

B. How many are female?
1. 0
2. 1
3. 2
4. 3-5
5. 6-10
6. More than 10

For Question B, I need to not allow the answer to be higher than the previous question. Is there an easy way to do this with conditions?

Thanks
Andy

Please Log in to join the conversation.

More
2 years 9 months ago #111743 by first
first replied the topic: Do not allow answers based on previous answers
This can be done question validation equation in question settings. Something like below.

B.NAOK <= A.NAOK

Survey Designer and Programmer

Please Log in to join the conversation.

More
2 years 9 months ago - 2 years 9 months ago #111745 by andogro
andogro replied the topic: Do not allow answers based on previous answers
Thank you for the response - I'm glad to know it can be done. Can you give me a more specific example of what the code might look like? I see the relevance equation area for the question and already have some conditions set there, but am wondering how I would code.

In a similar vein, I have other questions that are type in answers - for example "How old were you the first time you smoked cigarettes" and the second question is "How old were you when you started smoking a pack a day". The second question must be equal or greater than the first.
Last Edit: 2 years 9 months ago by andogro. Reason: needed to add more

Please Log in to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now