Welcome to the LimeSurvey Community Forum

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

hide question if previous multiple choice question is empty

  • keunes
  • keunes's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
7 years 11 months ago #135024 by keunes
I found in the wiki how to hide a question if another question is empty, but this ( [tt]!is_empty(SITU_1_BRAN)[/tt] ) doesn't work if the independent/first question is a multiple choice question. How to solve? I could add every single sub-question of the MC question, but that's a lot of copy-paste-edit.

I tried adding a regular expression ( [tt]!is_empty(SITU_1_BRAN_{[1-18]})[/tt] ) but that didn't work either, as the 'syntax is not supported' (or maybe I'm using the wrong syntax/using the syntax wrongly).
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
7 years 11 months ago #135055 by DenisChenu
See : manual.limesurvey.org/Expression_Manager....27that.27_variables

{count(that.SITUx1xBRAN.NAOK)>0}

BUT it don't work with SITU_1_BRAN due to _

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The following user(s) said Thank You: keunes
The topic has been locked.
  • keunes
  • keunes's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
7 years 11 months ago #135069 by keunes
Thanks so much!

Yesterday I installed the latest version of LS on my own website (rather than relying on an old version provided by my university) and that meant that the underscores were all removed. So it works now I entered [tt]count(that.SITU1BRAN.NAOK)>0[/tt] in the relevance equation.

I think I should do a regex course or sth before being able to understand the LS wiki :P
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose