Explore the community Forums Lectora Lectora Suggestions Showing multiple checkbox answers in student workbook Reply To: Showing multiple checkbox answers in student workbook

#387935 Score: 0
Profile photo of Jason Dalrymple
Jason Dalrymple
wise owl
curious george
friend finder
picture perfect
54 pts

Hi Karyn – The tricky part with multiple choice questions with check boxes is that the variable is set to “check1,check2,check3” etc., so you can’t use the native value for the variable very easily.

I worked with @klaatu some time back on styling text boxes that have a Change Contents so that I could add bullets or change font colors, since that can’t be done natively. I’m posting a similar solution that allows you to change the text, add line breaks, and style the text box when the user submits the answer.

In a nutshell, the submit buttons uses JavaScript to change value of the variable from a single line with commas to “individual” lines of text. It then looks at which values have been selected and displays them with a break in between. The button also sets the style for the text block by adding class to the text box. The style is written into the CSS file, which can be quickly edited to meet your needs.

The only thing I didn’t/couldn’t get to was the possibility of having each line of text styled differently, if that’s what you were looking for as well.

Hope this helps in the meanwhile!