Here's an example of how to set a quota depending on the first two options of a multiple-options question being checked.
Set up your survey to use JavaScript.
Create a yes-no question on the same page as the multiple options question.
Add the following script to the yes-no question. Replace "11" with the ID of the multiple-options question and "22" with the ID of the yes-no question.
The script:
- hides the yes-no question
- puts a listener on the multiple-options checkboxes so that if the first two options are checked the yes-no is set to "Yes", otherwise the yes-no is set to "No".
You can then set a quota on the yes-no question.
<script type="text/javascript" charset="utf-8">
$(document).ready(function(){
var q1ID = 11;
var q2ID = 22;
// Hide the hidden question
$('#question'+q1ID+'').hide();
// A listener on Q1 checkboxes
$('#question'+q1ID+' input.checkbox').click(function () {
// Count the checked boxes and populate the hidden question accordingly
if ($('#question'+q1ID+' input.checkbox:eq(0)').attr('checked') == true && $('#question'+q1ID+' input.checkbox:eq(1)').attr('checked') == true) {
$('#question'+q2ID+' input.radio:eq(0)').attr('checked', true);
}
else {
$('#question'+q2ID+' input.radio:eq(1)').attr('checked', true);
}
});
});
</script>