Back to Previous

Multiple Choice

The following example demonstrates the use of a pulldown list to allow the user to choose the best answer. Radio buttons could have been used as well.

The pulldown list here uses director’s built-in drop menu behavior along with my own "Dropdown Menu Submitter" behavior to make the selected choice fill a hidden text field. This field can then be queried for the answer when the time comes using the "Check Multi Choice Answer" behavior. Directors built in Dropdown List behavior works great in that you need only drag the behavior to a standard field with all your choices (can it get any simpler?)

As I mentioned, the results are stored in a hidden text field. I have stored them in hidden fields as opposed to a list(array) because I wanted a really easy way to see the results during my authoring, plus it keeps me from having to make a global list(movie script) just to test an answer. Of course, If you are tracking the answers over multiple frames, a global list will then become a necessity.

One thing to note is that the familiar “drop arrow” is not automatically made so I have created a “drop arrow” to place over the far right of the menu to make it actually look like a pull-down menu. The correct answer to this example is “C”        

   

__________________________________________________________

This example uses my custom “On Click Member Change For Multiple Members” behavior to make 3 check boxes swap their members when clicked. Their current state is then stored in a unique list name (that you can define) and then queried for the correct answer via my “Check 2 Multi Choice Answers” behavior. Try out the example below. Incorrect answer will prompt you with “try again”.

Hidden text fields are not used in this example. Instead, a global list is now used to store the on and off states (which are basically your answer). Since it uses a global list, you must include my custom “Multiple Global List for Member Change” behavior. Make sure the global behavior is tagged as a movie behavior/script so it can be recognized by every element in the project.

__________________________________________________________

Choose all that apply (Combo Multi Choice Example)

This example uses both a pulldown menu and multi choice. Correctness is only judged if both are correct. The correct answer will be “C” and "Yes". Give it a try.