Welcome, Guest
Username: Password: Remember me

TOPIC: Multiple Choice - Restricting Answer Choices based on Answer

Multiple Choice - Restricting Answer Choices based on Answer 3 years 2 weeks ago #84679

Hello everyone,

I was wondering if anyone could help me in the following issue. I am trying to design a Multiple Choice question whose choices depend on a previous question. For example:

Question 1: What is the name of each person in your immediate family?
Blank 1: Max
Blank 2: Michelle
Blank 3: Martin
Blank 4: {blank}
Blank 5: {blank}
Blank 6: {blank}
etc.


Question 1 is designed using the built-in question type "Multiple Text."

Question 2: Please select the immediate family members who live in your residence.

For this question, I am currently using the question type "Multiple Choice" with the answer from Question 1 (persons in the family) as Subquestion/Choices options. The problem is with this is, the "blanks" show up as subquestions/choices as well. Is there a way to tell lime-survey to not include the blanks?

Thanks in advance for your help! Let me know if I can clarify further!
Last Edit: 3 years 2 weeks ago by freytheviking.
The administrator has disabled public write access.

Multiple Choice - Restricting Answer Choices based on Answer 3 years 2 weeks ago #84685

  • TMSWhite
  • TMSWhite's Avatar
  • Offline
  • LimeSurvey Team
  • Posts: 759
  • Thank you received: 83
  • Karma: 37
Just use the array filter feature - it does exactly what you're asking.

Here is the sample survey

File Attachment:

File Name: limesurvey...9561.lss
File Size:30 KB


Here is what it looks like running:



And here is how you get the second set of sub-questions to show the values you entered in the first question:



/Tom

This message has attachments images.
Please log in or register to see it.

This message has an attachment file.
Please log in or register to see it.

The administrator has disabled public write access.

Multiple Choice - Restricting Answer Choices based on Answer 3 years 2 weeks ago #84718

TMSWhite wrote:
Just use the array filter feature - it does exactly what you're asking.

Here is the sample survey

File Attachment:

File Name: limesurvey...9561.lss
File Size:30 KB


Here is what it looks like running:



And here is how you get the second set of sub-questions to show the values you entered in the first question:



/Tom

Thanks! I will try it out!
The administrator has disabled public write access.

Multiple Choice - Restricting Answer Choices based on Answer 3 years 2 weeks ago #84720

Tom,

I can't seem to be able to get it working. I tried the "Array Filter" option, entering "q01" (the previous question's code) as my source, but it gave me the same result as previously.

Here is a screen shot of my subquestions, output, as well as the "Advance Options" page. Please let me know what I'm doing wrong? Oh, and I'm using version 1.92+. Thanks in advance again!









This message has attachments images.
Please log in or register to see it.

Last Edit: 3 years 2 weeks ago by freytheviking.
The administrator has disabled public write access.

Multiple Choice - Restricting Answer Choices based on Answer 3 years 2 weeks ago #84721

  • TMSWhite
  • TMSWhite's Avatar
  • Offline
  • LimeSurvey Team
  • Posts: 759
  • Thank you received: 83
  • Karma: 37
There are two likely possibilities:
(1) Is the first question actually "q01"? Filters are case sensitive, so if it is "Q01", the filter won't work.
(2) You are using an older version of 1.92+ (since it doesn't have Array Filter Style), so it is possible there is a bug in your version which has been fixed in more recent releases.
The administrator has disabled public write access.
Moderators: ITEd
Time to create page: 0.162 seconds