Attached you find three array questions. Answering the first one now leads to showing the same categories (courses) at the second and third question, regardless of the answers given at the first question.
However, the second and third question should only present the corresponding categories of the first question if the respondent answered NOT “None”.
How can this be programmed in LimeSurvey? Do we need Expression Manager to accomplish this? If so, what is the script? Thank you!
that's easy.
In the second and third matrix you use relevance:
See screenshot
The relevance is like : mat1_SQ001!="A1" with
"mat1" the questioncode
SQ001 the code of subquestion
A1 the code of answer option.
See example in second and third screenshot.
Best regards
Joffm
P.S. You didn't tell us which LS version you use.
The screenshot looks like 2.05/2.06.
Then it's the same procedure but the screen looks like screenshot 4 (you have to click the "R" to enter the relevance.
Volunteers are not paid.
Not because they are worthless, but because they are priceless
Thanks for your reply. Our version of LimeSurvey is 2.05. I don’t see the Relevance button so it looks like your version does not work in our version. It seems that this function is implemented as of version 2.06.
We’ve tried to directly use your Relevance code (of course with our own question and answer codes), but the result is the same. The categories in the first question that are answered “None” still are presented in the following questions. These categories should remain hidden.
Since you stated this to be an easy “issue”, perhaps you could help us out in version 2.05.
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member. -
Professional support
-
Plugins, theme and development
. I don't answer to private message.
Thanks for your reply. It works perfect when I use it in a group, i.e. when these questions are presented on one page.
We would like to use the same procedure in a questionnaire with only one question per page. When I try this with your script, on the next page I only see the question and the label names but not the categories which I answered other than “none” on the previous page . Do you know how to make your script work in a questionnaire with one question per page?
My workaround will only work if the hidden question can be placed on the same page as the array. JavaScript can only manipulate elements on the same page.
Cheers,
Tony Partner Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.