Willkommen, Gast
Benutzername: Passwort: Angemeldet bleiben:

THEMA: Validating dropdowns!

Validating dropdowns! 7 Monate 3 Wochen her #112048

  • nimbusgb
  • nimbusgbs Avatar
  • OFFLINE
  • Fresh Lemon
  • Beiträge: 2
  • Karma: 0
I want users to select 3 options from a dropdown list.

Question 1 - select your first option - dropdown list of options

Question 2 - select your second option - dropdown list of options < same list here >

Question 3 - select your third option - dropdown list of options < same list here >

The validation needs to be something like
Q1<>Q2 && q1<>q3 && q2<>q3

Dropdowns do not enable the validation portion in the admin section so i have three avenues to explore

1 - build a new question type, identical to dropdowns but with validation enabled.

2 - workaround?

3 - hack the core to enable validation on dropdowns!


Any suggestions?
Letzte Änderung: 7 Monate 3 Wochen her von nimbusgb.
Der Administrator hat öffentliche Schreibrechte deaktiviert.

Validating dropdowns! 7 Monate 3 Wochen her #112049

  • nimbusgb
  • nimbusgbs Avatar
  • OFFLINE
  • Fresh Lemon
  • Beiträge: 2
  • Karma: 0
May have solved this ....

use array question type!

:blush:
Der Administrator hat öffentliche Schreibrechte deaktiviert.

Validating dropdowns! 7 Monate 3 Wochen her #112063

  • tpartner
  • tpartners Avatar
  • OFFLINE
  • LimeSurvey Team
  • Beiträge: 4720
  • Dank erhalten: 953
  • Karma: 410
So, I think your validation requires that you cannot select duplicate answers in any question.

How about using multiple-choice questions with minimum and maximum answers set to 1 (requires a single answer for each question).

Then you can use the "Array exclusion filter" setting to remove the answer options from Q2 and Q3 as they are selected in previous questions.

If everything is on a single page, I would also use relevance to only show Q2 and Q3 when the previous question has been answered.


.
Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
Letzte Änderung: 7 Monate 3 Wochen her von tpartner.
Der Administrator hat öffentliche Schreibrechte deaktiviert.
Moderatoren: ITEd
Ladezeit der Seite: 0.122 Sekunden
Donation Image