Choice questions get information by asking users to make one or more selections from a list of choices.
The Interact Web Designer provides you with the following choice types:
|Yes/No||Users select one of two possible answers. The answers may be literally Yes or No, as in the example above, or they may consist of any other wording (e.g., Loans or Lines of Credit).|
|Users select one or more answers from a list of choices. Multiple Selection questions can be populated in runtime with values returned from an external data source (Dynamic choices), or from values entered manually (regular choices).|
|Users select one answer from a list of choices. The list of choices can be entered manually (regular choices), or it can be populated in runtime with values returned from an external data source (Dynamic choices).|
The figure below provides examples of each.
Note: A related type of single selection choice question is a Two-Level Menu page. With Menus the choice list also can be displayed as images, and after making a choice users go directly to the next page without having to click Next.
Choice Question Design: Basic Workflow
- Select Choice Type. From the Page Editor, select the desired type of choice question and drag it onto the Page map. (In the example above, a Yes/No type question is selected.) When a question type is dragged onto the Page map, the Element tab (on the right side of the Page Editor) automatically opens.
- Add the Choice Question. The Label is the question that the user will sees in runtime. The Designer has a default label for every choice question, which can be replaced with text that is relevant for your question.
- Define the Choices. Here you build the actual list of choices that the user sees in runtime. List options will depend on your choice type (Yes/No, Multiple or Single Selection). In our example we've used a Yes/No type question. The choice list can be built from regular (static) or Dynamic choices, as described above.
- Set the Display Type. Most choice type questions allow you to specify the format in which the choices are displayed. The different display types and the question types that support them are summarized in the following table:
Display Type Supported For: Switch Yes/No types Radio Buttons Yes/No types, Single Selection types Buttons Matrix Single Selection types List of Buttons Yes/No types, Single Selection types Dropdown List Single Selection types Multiple Selection (Checkboxes) Single Selection types, Multiple Selection types
- Set Validation and Security Settings. These optional settings provide additional checking and protection for sensitive user input.
The following settings are common to all choice questions:
- Required Field. When selected, users cannot proceed to the next page of the Interaction if they have not provided an answer. Required fields are indicated in an Interaction page by a red asterisk next to the label.
- Do not audit the question's answer. When selected, the answer provided by the user is not saved in the Interact databases.
- Set a Variable for Choice Selection Input. A Question Name or Variable Name field appears, depending on the choice question type. This field stores the runtime response as a User Input variable in order to make it readily available to other Interaction elements. (For details on using choice selections in variables, see Using Choice Selections in Other Elements.) A unique name is automatically assigned by default, but you can enter a more descriptive name of your own.
For Variable Name fields you can also assign the runtime response to an existing or new Variable. Entering '@' in the field enables you to select and assign a variable of the correct type using the autocomplete variables list. For more information, refer to Viewing and Managing Variables.
- Add Show/Hide Rule. The optional Show/Hide Rule field enables you to show or hide the choice question during runtime if a specified Rule condition is met. Choice questions are always displayed by default. For more information, refer to Dynamically Displaying Elements with Rules.
- Set a HTML Reference ID. On some choice question types, this field stores the choice response in order to make it available for use outside of Interact, for example in CSS or application extensions. A unique name is automatically assigned to this field by default, but you can assign a more descriptive name to make it easier to identify.
Using More than One Choice Question on a Visual Page
When you design your choice questions, keep in mind that a Page can display multiple questions (as in the example above).
When there is more than one choice question, you'll need to indicate which choice question will determine the Interaction flow after a selection is made. The checkbox This will create multiple paths in your script is provided for this purpose, as shown below:
Only one of the checkboxes can be selected to guide the Interaction flow on any Page.