CheckBoxOnClick

Help Contents GUI programming CheckBoxes CheckBoxOnClick
CheckBoxDestroy CheckBoxValue

CheckBoxOnClick acheckbox instructionlist


Command that sets the onClick event handler of the CheckBox acheckbox to the commands in the instructionlist.

Examples:

cb=CheckBox [][Hide Turtle][
	ifelse CheckBoxValue cb [hideTurtle][showTurtle]
	updateGraph]
CheckBoxOnClick cb [
	ifelse CheckBoxValue cb [pr [Yes, Sir!]][pr [No, Sir!]]
	updateGraph]
CheckBoxOnClick cb []	;like disabling the CheckBox

Reference:

CheckBoxDestroy CheckBoxValue