This functionality allows you to use logic within a page, and enables parts of a page to be updated based on responses to one or more questions on the same page. This can enable you to, for example, cause additional questions to appear on the page once the respondent has answered the first question. The functionality is based on the Ajax technology, and uses one (or more) questions as a trigger to activate logic in subsequent questions.
Note: Dynamic Questions only functions within page objects, and the trigger question(s) and the question(s) to be triggered, must be on the same page in the survey.
The following questionnaire logic can be used within pages and will update based on the triggers:
- Text substitution/response piping.
- Question masking.
- Column masking.
- Code masking.
- Scale masking.
Inside the question that you want to be dependent of responses to one or more questions on the same page, you can specify those other questions as “triggers”. This means that for every change to one of the trigger questions, the question will be updated with questionnaire logic like for example masking being reevaluated.
Note that this is only supported within the “Page” object, so the “Triggers” tab will only be available on questions within a page.
Figure 1 - Specifying a question as a trigger
Note: The Dynamic Questions functionality is not supported in the CAPI/Kiosk console. Dynamic Questions is supported in IE8+ (Windows), Firefox 10+ Google Chrome 26+ and Safari 5.1+ (Mac only). The functionality is only available in surveys using Survey Layouts.
Unlike Advanced WI features, Dynamic Questions have no automatic alternative way of presenting the page if Dynamic Questions is not supported. A function DynamicQuestionsEnabled is provided to either screen or provide an alternative routing to respondents whose browser does not support Dynamic Questions.
Displaying a Dynamic Follow-Up Question in the same Page
If for example you want a rating question to be followed by an open text question if a negative response has been given, you can use the Dynamic Questions functionality to have that appear on the same page when the negative response is given.
If you place a single question q9 asking people to respond on a 5-point scale, and you have an open text question q10 that should be displayed when q9 is answered with “1” or “2”, you can use a question mask as shown below on the open text question:
f("q9")=="1" || f("q9")=="2"If you want these questions to appear on the same page, you can place them inside a Page object as shown below:
Figure 2 - Placing questions inside a page object
If you set “q9” as a trigger for q10, then q10 will be displayed automatically when a response is given on q9.
The DynamicQuestionsEnabled() function in the condition is used to ensure the page is only displayed to respondents who are answering in a browser that supports the functionality.