Introduction to the SelectionList Control
The SelectionList control displays a list of items and enables the user to select one or more of them. Applications can render the SelectionList control as a drop-down list box, a selection list box, a set of check boxes, or a set of option buttons (radio buttons). A SelectionList control must be placed within a Form or Panel control, or inside a control's template on a mobile Web page. You can also drag it onto a mobile user control page.
Because it does not support pagination, this control works best for short lists. To view more complex information from a database in tabular format, use an ObjectList control.
By default, applications render the SelectionList control as a drop-down list. Alter the default by setting the SelectType property. A value of DropDown for the SelectType property enables users to choose one item from the list. To enable them to select more than one item, set the SelectType property to CheckBox or MultiSelectListBox.
To define list items at design time, click the ellipsis button () in the control's Items property box in the Properties window. You can then define items using the SelectionList Properties dialog box.
Alternatively, your application can define the items at run time. This can be accomplished either programmatically or with data binding. The Items property is of type MobileListItemCollection. Therefore, applications add items programmatically using the Add method from the MobileListItemCollection class. Use the SelectionList control's DataMember, DataSource, DataTextField, and DataValueField properties to add items through data binding.
For information about validating user input to this control, see Introduction to the Validation Controls.