//更新资料 protected void Button1_Click(object sender, EventArgs e) { if (Page.IsValid) { bool check = true; Hashtable ht = new Hashtable(); foreach (string item in arr1) { ht.Add(item, Util.GetControlValue(this.timename.Parent.FindControl(item))); } if (ht["time0"].ToString().Trim() == "") { //Util.alert(this.Page, "错误信息:时效日期不能为空!"); //check = false; ht.Remove("time0"); } if (check) { U_ZCTimeBU time1 = new U_ZCTimeBU(); string remark; int parentid = time1.EditTimeData(Request["tcid"], ht, out remark); time1.Close(); string title = String.Format("{0}已修改了{1}时效管理数据,请审阅", User.Identity.Name, this.hidCorp.Value); //发送邮件 if (remark != "") { PubComm.SendMailToLeader(title, remark, Application["root"] + "/ZcMng2/ZcDetail1.aspx?id=" + this.HiddenField1.Value); } Response.Redirect("ZcDetail6.aspx?id=" + parentid, true); } } }