Help Contents / GUI programming / ChoiceBoxes / ChoiceBoxSetSelection

ChoiceBoxSetSelection achoicebox selection

Command to set the selection of the ChoiceBox achoicebox to the value selection. 

selection is a zero-based integer index into the choices, which must be less than the number of choices in the control. 

Example: 

	cb=(ChoiceBox [][MyChoiceBox] 
	[	[String 1] 
		[and a second string] 
		[and the last string] 
	] 
	[	(show "|MyChoiceBox| ChoiceBoxSelection) 
	]) 
	ChoiceBoxSetSelection cb 2 


previous: ChoiceBoxSelection	next: ChoiceBoxSetChoices
