Multiple choice and variables

Aug 26, 2014

Hello all

Here I am back with another puzzle that I'm sure the solution is just over the hill from me!

I am trying to create a custom exam in the format of a traditional multiple choice examination paper. The user decides which is the correct answer and then marks the correct box. My current demo (attached) allows the user to cheat by selecting every box. I need to work with my variables to limit the user to one choice per selection, but also to allow them to change their suggestion. This is proving beyond me at the moment. Any suggestions?

Many thanks

Andrew

5 Replies
OWEN HOLT

Without looking at your file, here would be my thought. Use a a variable to control selection. When the user makes a selection, check the variable to see that it is open/available for selection. Once the user clicks one selection, the variable updates (say from 0 to 1) and now when checking the variable, other selections are locked. Add a button labeled something like "make a new choice" that simply resets the variable back to its open state allowing any answer to be selected.

OWEN HOLT

Brilliant Michael. I never noticed this selection before (but I don't work much with buttons). Can you easily disable a set on selection of one member?
If not, an alternative would be to place a box over the buttons with 100% transparency and 2 states (normal and Active). Remove the box in the normal state (so there is no block). change the state of the box to Active when the user selects any button in the set. As long as the block sits on top of the buttons, it would prevent the user from changing their answer or exploring to find the right one.

Andrew Smith

Thanks guys.

Michael's button suggestion has worked a treat to enable only one selection per question. The problem I have now is that if the user chooses the correct answer first but then changes their selection to an incorrect answer, the score is not subtracted from the total. So ideally, I need to be able to subtract 1 from the total if a correct button is deselected. Any ideas on how to do that?

Ashley Terwilliger-Pollard

Hi Andrew,

What about a trigger with a condition - so something like, Subtract one from the variable when the user clicks the "correct" button, on the condition that the state of the correct button is selected - so this way it would be assuming the user had already selected the correct button and is not trying to unselect it?

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