ListBox
The ListBox
is an items control, which means that you can populate it with items that contain text or other controls.
By default, the ListBox
control allows the user to select a single item in the list. Multiple items can be selected if the ListBox.SelectionMode
property is set to Multiple
(see the previous section on the CheckBox
control, where a ListBox
was used to display a data bound collection).
The ListBox
control contains a list of ListBoxItem
controls. The ListBox
control is a remarkably flexible control because it allows you to not only display ListBoxItems
, but because the ListBoxItem
control is a ContentControl
any kind of object can be placed in a ListBox
(see Figure 5.12).
Get Windows® Phone 8 Unleashed now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.