Use of Variables in quiz question

Jan 31, 2019

I have a quiz question where the user clicks on a number of 'switches' ( 2 states -on & off) and then clicks another image hotspot to submit the answer. Each switch toggles an associated variable SW1, SW2 etc. The question can only be correct if  the correct values are assigned to each variable.

How can I submit the question being correct dependent on the variable values?

7 Replies
Joey Buys

Hi David

Is there a particular reason why need to assign variables to the switches?

Reason why I am asking: you can very easily achieve the same effect with a freeform Pick Many question. You will be able to add the switches as objects and switch between the 'on' and 'off' states via the object's 'normal' & 'selected' states. 

You can then switch to the question's 'Form View' and specify which objects (switches) should be on or not by marking the appropriate 'on' ones as the correct responses.

Judy Nollet

You could set up each switch so that the "Off" and "On" parts are separate objects (though they can be designed to look like one switch). That would allow for a free-form Pick Many in which the correct responses are the proper collection of Offs and Ons. FYI: That will require some extra programming to ensure that if someone selects On for a given switch, the corresponding Off is de-selected. 

This discussion is closed. You can start a new discussion or contact Articulate Support.