1、ArrayList数据列表(使用数据列表必须引入using System.Collections命名空间)
2、多态添加下拉列表项
protected void Button1_Click(object sender, EventArgs e)
{
DropDownList4.Items.Add(TextBox1.Text.ToString());
}
3、分别添加Text,Value值,与插入项
DropDownList4.Items.Add(new ListItem("111", "111"));
DropDownList4.Items.Add(new ListItem("122", "122"));
DropDownList4.Items.Insert(1, new ListItem("222", "222"));//插入到第2个位置