The Selectboxes component

Define a group of checkboxes in the form. This is similar to the Radio component, but allows for multiple selections at the same time.

In addition to the properties and methods listed below, this component inherits properties and methods from the superclass Component. For example, any Selectboxes component has a label and defaultValue property even though these are not explicitly listed here.


valuesSpecifies the options the user can choose from. Must be an array of values where each item has the following fields:
  • label: The text to show besides the option.
  • value: The value of the option.
Easily set this property with the setValues method.
inlineIf set to true, layout the checkboxes horizontally instead of vertically.BooleanFalse
labelPositionPosition of the label with respect to the select boxes. Can be 'top', 'bottom', 'right-right', 'left-right', 'left-left' or 'right-left'.String"top"
optionsLabelPositionPosition of the text of every option with respect to the checkboxes. Can be 'right', 'left', 'top' or 'bottom'.String"right"


setValuesobj​.setValues(​labels, values, defaults)Set the labels and accompanying values (keys). All values must be valid variable names. This sets the values property of the Selectboxes component. Optionally provide default values for the checkboxes.

The selectable options can be changed "after initialization" as well, as described in How to.

See also

  • Use the triggerHappy functionality to trigger an event whenever the value of the Selectboxes component is changed by the user.
  • Use the Radio to only allow for one selection.
  • Change the options of a Selectboxes component after initialization as described in How to.