Reset Grid Pager

  1. #1

    Reset Grid Pager

    Hi,

    I have a grid control and the conditions to the data soruce is passed via text fields in the page. When the page loads the conditions are empty so the grid loads all the data and show the page size, current page, and total number of pages in the pagerbar. But, when I give the condition and click on the search button I use grid.reload(), the grid is reloading with the data based on my conditions but the pager is not reset and still shows the old details(page size, current page, total pages, etc).

    Kindly, let me know how thie could be resolved.

    Thanks

  2. #2

    RE: Reset Grid Pager

    You have to set store id to pager control also. You need to refresh the store.

    
    
    
    
    <ext:Store ID="Store1" runat="server"........
    
    
    <ext:GridPanel ID="GridPanel1" runat="server" StoreID="Store1" ...................
    
    
    
    <ext:PagingToolBar ID="PagingToolBar1" runat="server" PageSize="10" StoreID="Store1" />
    Hope this helps.
  3. #3

    RE: Reset Grid Pager


    hi friend.

    I had the some problem . and solved it .
    you can set the page index of pagingtoolbar to 0...

    protected void cmbFilterCompany_ValueChanged(object sender, AjaxEventArgs e)        
    {
    
            ...............
    
          DataTable dtOfferList = Database.ExecuteDataTable(strQuery);
          PagingToolbar1.SetPageIndex(0);
    
           storeOffers.DataSource = dtOfferList;
           storeOffers.DataBind();        
    
    }
    I hope it helps you...

Similar Threads

  1. [CLOSED] Reset store's sort info on grid reload/reconfigure
    By jchau in forum 1.x Legacy Premium Help
    Replies: 6
    Last Post: Aug 10, 2010, 4:06 PM
  2. [CLOSED] [1.0] #{Store1}.removeAll() does not reset grid paging
    By bsnezw in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Jan 26, 2010, 1:22 PM
  3. Hide refresh button on Pager
    By Hari in forum 1.x Help
    Replies: 4
    Last Post: Jan 08, 2010, 11:12 PM
  4. [CLOSED] Pager broken?
    By tdracz in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Dec 17, 2008, 6:24 PM

Posting Permissions