Esempio n. 1
0
        protected void btnOK_Click(object sender, EventArgs e)
        {
            Mmessage.messageContent = this.FreeTextBox1.Text;
            Mmessage.messageNo      = Request["ID"].ToString();
            Mmessage.releaseDate    = DateTime.Now;
            Mmessage.memberNo       = this.txtUid.Text;
            Bmessage.Add(Mmessage);
            string strUrl = "LeaveWordView.aspx?ID=" + Request["ID"];

            Response.Redirect(strUrl);
        }
Esempio n. 2
0
 protected void btnOK_Click(object sender, EventArgs e)
 {
     if (Session["UserName"] == null)
     {
         Response.Redirect("Default.aspx");
     }
     else
     {
         Mmsg.messageNo      = msg.CreateNo();
         Mmsg.employeeNo     = "";
         Mmsg.memberNo       = Session["UserID"].ToString();
         Mmsg.releaseDate    = DateTime.Now;
         Mmsg.messageContent = this.FreeTextBox1.Text.ToString();
         Mmsg.replyContent   = "";
         Mmsg.replyDate      = DateTime.Now;
         msg.Add(Mmsg);
         string str = "<script language=javascript>alert('添加成功');location='Default.aspx';</script>";
         Response.Write(str);
     }
 }