It creates a multi selection check box group.
The ID
of the CheckBoxList is Check1
.
Two of its properties are set in ASP.NET:
Items
(inherited from ListControl), which is used to created the six items, Item 1, Item 2, ..., and Item 6
AutoPostBack
(inherited from ListControl), which gets or sets a value indicating whether a postback to the server automatically occurs when the user changes the list selection
The event SelectedIndexChanged occurs when the selection from the list control changes between posts to the server.
<asp:CheckBoxList ID="Check1" runat="server"
AutoPostBack="True"
onselectedindexchanged="Check1_SelectedIndexChanged">
The subroutine Check1_SelectedIndexChanged
is called when SelectedIndexChanged
.
The following three properties are used: