Welcome to the LimeSurvey Community Forum

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

show prior answer in depending question text

  • FranzGerbig
  • FranzGerbig's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
7 years 9 months ago - 7 years 9 months ago #138916 by FranzGerbig
Hello guys outthere,

does sb have a clue how to show a prior answer (a1) in a depending question text (q2, see below for an example syntax)?

q1: How many cars do you have?
a1: [0-99]

q2:
{if((q1== 1), "What's the colour of your car?", "")}
{if((q1 > 1), "What colours have your cars? Please name a colour for all of your q1.shown cars", "")}

using LS 3.13.2+180709
Last edit: 7 years 9 months ago by FranzGerbig. Reason: better understanding
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
7 years 9 months ago #138921 by DenisChenu
Replied by DenisChenu on topic show prior answer in depending question text
What is q1 question type ?

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 topic has been locked.
  • FranzGerbig
  • FranzGerbig's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
7 years 9 months ago #138923 by FranzGerbig
Replied by FranzGerbig on topic show prior answer in depending question text
q1 = Numerical input

using LS 3.13.2+180709
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Away
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
7 years 9 months ago #138927 by tpartner
Replied by tpartner on topic show prior answer in depending question text
Maybe you have a typo - that works for me in 2.50.

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The following user(s) said Thank You: FranzGerbig
The topic has been locked.
  • FranzGerbig
  • FranzGerbig's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
7 years 9 months ago #138933 by FranzGerbig
Replied by FranzGerbig on topic show prior answer in depending question text
I don't know :dry:
anyway, it works with

{if((q1== 1), "What's the colour of your car?", "")}
{if((q1 > 1), "What colours have your cars? Please name a colour for all of your ", "")} {if((q1 > 1), {tq1.shown}, "")}{if((q1 > 1), " cars.", "")}
:)

using LS 3.13.2+180709
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose