using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data.SqlClient;
public partial class CalendarManage_DiaryView : System.Web.UI.Page
{
    public string Titles;
    public string Addtime;
    public string Message;
    protected void Page_Load(object sender, EventArgs e)
    {
        SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["Connection"]);
        con.Open();
        int Notepaperid = Convert.ToInt32(Request["Notepaperid"].ToString());

        string sql = "select * from Notepaper where Notepaperid="+Notepaperid+"";
        SqlCommand com = new SqlCommand(sql,con);
        SqlDataReader dr = com.ExecuteReader();
        if (dr.Read())
        {
            Titles = dr["Title"].ToString();
            Addtime = dr["Addtime"].ToString();
            Message = dr["message"].ToString();
        }
        con.Close();
    }
}
