protected void Delete3_Click(object sender, EventArgs e) { try { if (dlistThirdClumName.SelectedItem.Value == "" && dlistThirdClumName.SelectedItem == null) { this.lblCheck.Text = "选择删除项为空"; } else { ThirdClassDm Third = new ThirdClassDm(); GA ga = new GA(); GAController GA = new GAController(); Third.ThirdClassDmName = dlistThirdClumName.SelectedItem.Text; if (GA.DeleteThirdClass(ga, Third)) { this.lblCheck.Text = "删除成功!"; //this.Page.ClientScript.RegisterStartupScript(this.GetType(), "", "<script language='javascript'>alert('" + "删除成功" + "');</script>"); } else { this.lblCheck.Text = "删除失败!"; //this.Page.ClientScript.RegisterStartupScript(this.GetType(), "", "<script language='javascript'>alert('" + "删除失败 " + "');</script>"); } } } catch { this.lblCheck.Text = "选择删除项为空"; } }