protected void BtnSave_Click(object sender, EventArgs e) { DateTime dateTime = default(DateTime); dateTime = DateTime.Now; DateTime dateTime2 = default(DateTime); dateTime2 = Convert.ToDateTime(this.txtCallDate.Text); Hashtable hashtable = new Hashtable(); hashtable.Add("UserCode", SqlStringConstructor.GetQuotedString(this.UserCode)); hashtable.Add("RecordDate", SqlStringConstructor.GetQuotedString(dateTime.ToString("yyyy-MM-dd"))); hashtable.Add("MeetingTitle", SqlStringConstructor.GetQuotedString(this.txtMeetingTitle.Text)); hashtable.Add("MeetingPlace", SqlStringConstructor.GetQuotedString(this.txtMeetingPlace.Text)); hashtable.Add("CallDate", SqlStringConstructor.GetQuotedString(dateTime2.ToString("yyyy-MM-dd"))); hashtable.Add("CallTime", this.ddltCallTime.SelectedValue.ToString()); hashtable.Add("CallMinute", this.ddltCallMinute.SelectedValue.ToString()); hashtable.Add("Content", SqlStringConstructor.GetQuotedString(this.txtContent.Text)); hashtable.Add("State", "0"); hashtable.Add("PigeonholeState", SqlStringConstructor.GetQuotedString("0")); if (this.RecordID == 0) { if (ConferenceManage.AddMeetingInfo(hashtable)) { this.JS.Text = "alert('保存成功!');window.returnValue=true;window.close();"; return; } this.JS.Text = "alert('保存失败!');"; return; } else { string where = " where RecordID = " + this.RecordID.ToString(); if (ConferenceManage.UpdMeetingInfo(hashtable, where)) { this.JS.Text = "alert('保存成功!');window.returnValue=true;window.close();"; return; } this.JS.Text = "alert('保存失败!');"; return; } }