
  public partial class DropDownList : System.Web.UI.Page
  {
      protected void Page_Load(object sender, EventArgs e)
      {
          if (!【IsPostBack】)
          {
              Button1.Text = "确定";
              DropDownList1.【Items】.Add("语文");
              DropDownList1.Items.Add("数学");
              DropDownList1.Items.【Add】("物理");
          }
      }
      protected void Button1_Click(object sender, EventArgs e)
      {
          Label1.【Text】 = "您选择的课程是:<font color=red>" + DropDownList1.【Selected】Item.Text + "<br></font>";
  
      }
  }
  

