using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;

public partial class newshow : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            shownews();
        }
    }
    private void shownews()
    {
        DataTable dt =new DataTable();
        if (Cache["ShowNews"] != null)
        {           
            dt =(DataTable) Cache.Get("ShowNews");           
        }
        else
        {
            int strwhere = 0;
            Cn1yw.BLL.Article bll = new Cn1yw.BLL.Article();
            DataSet ds = new DataSet();
            ds = bll.newshow(10, strwhere);
            dt = ds.Tables[0];
            Cache.Insert("ShowNews", dt, null, DateTime.Now.AddMinutes(720), TimeSpan.Zero);
        }

   }

}

相关文章:

  • 2021-11-21
  • 2021-11-22
  • 2021-09-22
  • 2022-01-04
  • 2022-12-23
  • 2022-12-23
  • 2021-08-01
猜你喜欢
  • 2022-02-27
  • 2021-11-20
  • 2021-08-30
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案