日期:2012-08-23  浏览次数:20497 次

using System;
using System.Data;
using System.Data.SqlClient;
using System.Web;
using System.Web.UI.WebControls;

namespace OSLeagueForumXP.admin
{
    /// <summary>
    /// 编辑公告页面
    /// </summary>
    public class EditBoardPage : System.Web.UI.Page
    {
        protected System.Web.UI.WebControls.HyperLink hlkPrev;
        protected System.Web.UI.WebControls.HyperLink hlkNext;
        protected System.Web.UI.WebControls.HyperLink hlkFirst;
        protected System.Web.UI.WebControls.HyperLink hlkEnd;
        protected System.Web.UI.WebControls.Label lblPage;
        protected System.Web.UI.WebControls.Panel pelMain;
        protected System.Web.UI.WebControls.Label lblMessage;
        protected System.Web.UI.WebControls.HyperLink hlkReturn;
        protected System.Web.UI.WebControls.Panel pelMessage;
        protected System.Web.UI.WebControls.DataList DLBoard;
    
        private void Page_Load(object sender, System.EventArgs e)
        {
            Process clsProcess = new Process();
            clsProcess.Common();
            
            const int PAGESIZE = 5;
            int intPageCount;
            int intPage;
            if(Request.QueryString["Page"] == null)
            {
                intPage = 1;
            }
            else
            {
                intPage = Int32.Parse(Request.QueryString["Page"]);
            }
            int intStart = (intPage - 1) * PAGESIZE;
            
            SqlDataReader SqlReader = clsProcess.GetBoardCount();
            if(SqlReader.Read())
            {
                intPageCount = (int)SqlReader["PageCount"];
            }
            else
            {
         &