Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Text display page showing survey Q & A not working for dropdown answer

  • Rimfaxe2
  • Rimfaxe2's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
3 years 5 months ago - 3 years 5 months ago #206943 by Rimfaxe2
Hi' all, I m a real beginner and hope this ? is not vasting your time. I am running LS 3.21.1+191210 on debian 10.
In a survey I display the respondents Q & A on a text display page using codes given here

manual.limesurvey.org/ExpressionScript_e...e_using_placeholders

For one Q&A pair of type dropdown I get the proper respons for the Q, but "-oth" for the answer. This is obviously wrong, as none of the answers includes this string - but I cannot find the reason for this (to the best of my limited knowledge) misbehaviour.
Any help is appriciated.

Post thoughts..
I seems as if this respons comes only, for the choice "Other in the dropdown (a not-in question setting). Also the choice "Other" results in an extra question that prompts the respondent to elaborate on "Other". This elaboration does not have a qid how is that?
Last edit: 3 years 5 months ago by Rimfaxe2. Reason: Just got an idea..
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
3 years 5 months ago #206945 by holch
-oth- stands for "other", obviously. It means that the responde "other" was chosen. I never use this question type, but probably with Qx_other you should be able to access the response.

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

The following user(s) said Thank You: DenisChenu
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
3 years 5 months ago #206946 by holch
Qx == your question code. Next time, provide a LSS-Export of just the relevant part of the survey (copy the survey, delete everything necessary in this copy and export it as LSS).

This way we can see what you are doing and how your structure works.

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

The following user(s) said Thank You: Rimfaxe2
The topic has been locked.
  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
3 years 5 months ago #206956 by Joffm

I seems as if this respons comes only, for the choice "Other in the dropdown (a not-in question setting). Also the choice "Other" results in an extra question that prompts the respondent to elaborate on "Other". This elaboration does not have a qid how is that?


Exactly.
If you use the "Other" option in your question LS uses the code "-oth-" to store this.
Which code do you expect? LS can't know how you coded the answer options.
And how do you expect the "Other" to be captured. There has to be a text field to enter the answer.
And in the next column (called "QCode_other") the verbatim of this "Other" ist stored.

If you want to display the text of the given answer for the "normal" option and for the "other" option you have to use the IF-statement.
If the code ist "-oth-" diplay the "other" verbatim else display the answer option text.

{if(QCode=="-oth-",QCode_other,QCode.shown)}

Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless
The following user(s) said Thank You: DenisChenu
The topic has been locked.
  • Rimfaxe2
  • Rimfaxe2's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
3 years 5 months ago #206958 by Rimfaxe2
Thank you,

So far I got around the challenge by creating another question and just show it if the previous question is answered with "Other". I look forward to learning more about the syntax and possibilities in the Expression manager.
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose