checkboxlist items als Standardeinstellung im codebehind asp.net

Meiner Seite habe ich ein CheckBoxList Kontrolle und ich habe 7 Punkte. Ich würde gerne diese 7 Gegenstände als aufzugebendes in meinem Page_load codebihind.

meiner Seite:

<asp:CheckBoxList ID="WeeklyCondition" runat="server">
    <asp:ListItem Value="1">Sat</asp:ListItem>
    <asp:ListItem Value="2">Sun</asp:ListItem>
    <asp:ListItem Value="3">Mon</asp:ListItem>
    <asp:ListItem Value="4">Tue</asp:ListItem>
    <asp:ListItem Value="5">Wed</asp:ListItem>
    <asp:ListItem Value="6">Thu</asp:ListItem>
    <asp:ListItem Value="7">Fri</asp:ListItem>

</asp:CheckBoxList>
Schreibe einen Kommentar