Count multiple select checkbox even if it gets unchecked | XM Community
Skip to main content

Qualtrics only counts a multiple select check box as selected if the box is selected when the page is submitted. However, I would like to be able to count how many respondents selected a multiple select check box even if they then uncheck the box before submitting the page.
Context for my request: To allow respondents to refresh their memory about a long description, I use a multiple select check box on the page with in-page display logic to display the description. Respondents can select the box to open the text description and then uncheck the box to again hide the description. My goal here is to be able to determine a count and proportion of respondents who use the reminder checkbox, counting both those who left the box checked when submitting page and those who unchecked the box after reading the text.

You can add a variable and then increment it on click like below:
var incr=0
jQuery('input[type="checkbox"]').click(function() {
incr++;
})


grahulp5, thanks for the suggestion. Could you help me with the function script to set this variable to an embedded data variable?
Would it be something like...
{Qualtrics.SurveyEngine.setEmbeddedData("Q1SelectCount", incr);}


Leave a Reply