| 1 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 2 |
% |
| 3 |
% CHECK BOX LATEX FILE EXAMPLE: USES QUESTIONANDRESPONSES COMMAND, 7 ARGUMENTS |
| 4 |
% 1ST ARGUMENT INDICATES THIS IS "CHECK" TYPE QUESTION |
| 5 |
% 2ND, 3RD, 4TH ARGUMENTS GIVE NAMES OF PREVIOUS, INDEX, NEXT LINKING FILES |
| 6 |
% 5TH ARGUMENT GIVES QUESTION, WITH UP TO 5 CHECK BOXES, AND |
| 7 |
% WHETHER OR NOT THESE CHECK BOXES ARE "ON" OR "OFF" |
| 8 |
% ANY WHERE FROM NONE TO FIVE CHECK BOXES ARE ALLOWED TO BE "ON" |
| 9 |
% 6TH, 7TH ARGUMENTS GIVE RESPONSES IF USER ANSWER CORRECT OR INCORRECT |
| 10 |
% |
| 11 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 12 |
\documentclass[dvips]{article} |
| 13 |
\usepackage{interactiveworkbook} % put in style directory; cannot appear in any other directory |
| 14 |
|
| 15 |
\begin{document} |
| 16 |
|
| 17 |
% question and responses has *seven* arguments |
| 18 |
\questionandresponses{check} % check box kind of question |
| 19 |
{ndex.pdf}{ndex.pdf}{popup.pdf} % previous, index and next files are 2nd, 3rd, 4th arguments |
| 20 |
{Question 1. $\;$ A multiple check box question. \\ \\ % question is 5th argument |
| 21 |
% "checkbox..." is for question taker, "answercheck..." is for question giver |
| 22 |
% "checkbox..." appears on screen; "answercheck..." does not appear on screen |
| 23 |
% up to five check boxes can be "X"ed |
| 24 |
\noindent |
| 25 |
\checkone Off \answercheckone{Off} \\ |
| 26 |
% correct answer, next, has check box "On" ("X"ed) |
| 27 |
\checktwo On \answerchecktwo{On} \\ |
| 28 |
% correct answer, next, "Off" (un"X"ed) |
| 29 |
\checkthree {\it no} X \answercheckthree{Off} \\ |
| 30 |
\checkfour X \answercheckfour{On} \\ |
| 31 |
\checkfive {\it do not} click \answercheckfive{Off} |
| 32 |
} % end of 5th argument |
| 33 |
{Yes, correct.} % correct response hint is 6th argument |
| 34 |
{No, try again.} % incorrect response hint is 7th argument |
| 35 |
|
| 36 |
\end{document} |