请教动态添加控件的问题
此方法可以添加一个控件,但是如何多次添加多个控件呢?protected void Button2_Click(object sender, EventArgs e)
{
String str_a;
str_a = txt_1.Text.ToString();
CheckBox chb;
chb = new CheckBox();
chb.Text = str_a;
pnl.Controls.Add(chb);
}
2014-03-15 17:51
2014-03-16 15:57
2014-04-22 14:35