コード例 #1
0
 void gvSS_PageIndexChanging(object sender, GridViewPageEventArgs e)
 {
     gvSS.PageIndex = e.NewPageIndex;
     Erc.Apple.Data.SuccessStories ss = new Erc.Apple.Data.SuccessStories();
     ssList = ss.GetByLang(this.CurrentLanguage);
     if (ssList != null && ssList.Count > 0)
     {
         gvSS.DataSource = ssList;
         gvSS.DataBind();
     }
 }
コード例 #2
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!this.IsPostBack)
            {
                Erc.Apple.Data.SuccessStories ss = new Erc.Apple.Data.SuccessStories();
                ssList = ss.GetByLang(this.CurrentLanguage);
                if (ssList != null && ssList.Count > 0)
                {
                    //rptSuccessStories.DataBinding += new EventHandler(rptSuccessStories_DataBinding);
                    gvSS.DataSource = ssList;

                    gvSS.DataBind();
                }
            }
            gvSS.PageIndexChanging += new GridViewPageEventHandler(gvSS_PageIndexChanging);
        }