Drop box

More
1 month 3 weeks ago #159693 by adridg
adridg created the topic: Drop box
I have a drop box question with numbers as answer.
Each number is related to a person´s name.
I want that, when a number is choosen in the drop box list, the name related will appear.
Is that possibel?
Thanks

Please Log in to join the conversation.

More
1 month 3 weeks ago #159699 by Joffm
Joffm replied the topic: Drop box

I want that, when a number is choosen in the drop box list, the name related will appear.

Where?

Please Log in to join the conversation.

More
1 month 3 weeks ago #159703 by adridg
adridg replied the topic: Drop box
Could it be in the same question, but not in the drop box. Like an text with the name.
Or in the next question. Wuld be like an validation, if the person choose the correct number.
I hope now is clear...

Please Log in to join the conversation.

More
1 month 3 weeks ago #159715 by Joffm
Joffm replied the topic: Drop box
Hello, aldridg,
Always the same: The Buzzword is "Tayloring".
https://manual.limesurvey.org/Expression_Manager#Tailored_Questions.2C_Answers.2C_and_Reports

Just include in the question text something like this:

{if(Q1==1,"Hi, Angela, nice to see you",if(Q1==2,"Hi, Bert, nice to see you",if(Q1==3,"Hi, Carmen, nice to see you",if(Q1==4,"Hi, Dan, nice to see you",if(Q1==5,"Hi, Eileen, nice to see you",if(Q1==6,"Hi, Fred, nice to see you",""))))))}



and then


Of course you are free to include this in a different page.
Attachments:
The following user(s) said Thank You: adridg

Please Log in to join the conversation.

More
1 month 2 weeks ago #159975 by adridg
adridg replied the topic: Drop box
I did this, but apparently i´m missing something:
when i did with the first question as drop box, the names did not appear.
when I change the drop box question to short free text, it works
what am i doing wrong?
thank you

Please Log in to join the conversation.

More
1 month 2 weeks ago #159976 by Joffm
Joffm replied the topic: Drop box
Hello, adridg,

where is your sample survey?

How can we know what you are doing wrong or what you are missing?

Best regards
Joffm

Please Log in to join the conversation.

More
1 month 2 weeks ago #159978 by adridg
adridg replied the topic: Drop box
sorry :blush:
Attachments:

Please Log in to join the conversation.

More
1 month 2 weeks ago - 1 month 2 weeks ago #159980 by Joffm
Joffm replied the topic: Drop box
Hello, adridg,
Your test was against the text of the answer option.
But you must test against the code.
{if(Matr=="A1","ADALBERTO MARTINS",if(Matr=="A2","ÁLVARO ALVES NÔGA",if(Matr=="A3","BEATRIZ DE LIMA PEREIRA","")))}

Or if you want to use the matricula, you have to test:
{if(Matr.shown=="45446","ADALBERTO MARTINS",if(Matr.shown=="66818","ÁLVARO ALVES NÔGA",if(Matr.shown=="66834","BEATRIZ DE LIMA PEREIRA","")))}

The explanation you find - as usual - in the manual:
https://manual.limesurvey.org/Expression_Manager#Access_to_Variables




Best regards
Joffm
Attachments:
Last Edit: 1 month 2 weeks ago by Joffm.
The following user(s) said Thank You: adridg

Please Log in to join the conversation.

More
1 month 2 weeks ago #159983 by adridg
adridg replied the topic: Drop box
thank you!!!

Please Log in to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now
Join our Newsletter!