62,269
社区成员
发帖
与我相关
我的任务
分享 protected void Button1_Click(object sender, EventArgs e)
{
string ert = CheckBoxList1.Text;
foreach(char se in CheckBoxList1.Text)
{
Label1.Text += se.ToString();
}
}
for (int i = 0; i < CheckBoxList1.Items.Count;i++ )
{
if (CheckBoxList1.Items[i].Selected == true)
{
Label1.Text += CheckBoxList1.Text.ToString();
}
}
string s = "";
for (int i = 0; i < cbList.Items.Count; i++)
{
if (cbList.Items[i].Selected == true)
{
s += cbList.Items[i].Text;
}
}
for (int i = 0; i < CheckBoxList1.Items.Count;i++ )
{
if (CheckBoxList1.Items[i].Selected == true)
{
Label1.Text += CheckBoxList1.Text.ToString();
}
} foreach (ListItem item in CheckBoxList1.Items)
{
if (item.Selected)
{
Label1.Text += item.Text;
}
}
for (int i = 0; i < CheckBoxList1.Items.Count; i++)
{
if (CheckBoxList1.Items[i].Selected)
{
Label1.Text += CheckBoxList1.Items[i].Text;
}
}