Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6936375
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T12:13:33+00:00 2026-05-27T12:13:33+00:00

i have a paging grid and some function that load a new store to

  • 0

i have a paging grid and some function that load a new store to the grid, but when i click on the next page it reverts back to the initial store

the grid:

Ext.define('Pedido', {
    extend: 'Ext.data.Model',
    fields: [{
        name: 'ID',
        type: 'int'
    }, {
        name: 'Nome',
        type: 'string'
    }, {
        name: 'CPF/CNPJ',
        type: 'string'
    }, {
        name: 'Data',
        type: 'datetime'
    }, {
        name: 'TipoPagamento',
        type: 'string'
    }, {
        name: 'StatusPagamento',
        type: 'string'
    }, {
        name: 'TipoPagamento',
        type: 'string'
    }, {
        name: 'Total',
        type: 'string'
    }],
    idProperty: 'ID'
});

var store = Ext.create('Ext.data.Store', {
    pageSize: 10,
    model: 'Pedido',
    remoteSort: true,
    proxy: {
        type: 'ajax',
        url: 'http://localhost:4904/Pedido/ObterPedidosPorInquilino',
        reader: {
            root: 'Items',
            totalProperty: 'TotalItemCount'
        }
    }
});

var grid = Ext.create('Ext.grid.Panel', {
    id: 'grid',
    width: 500,
    height: 250,
    title: 'Array Grid',
    store: store,

    loadMask: true,
    viewConfig: {
        id: 'gv',
        trackOver: false,
        stripeRows: false
    },
    columns: [{
        id: 'gridid',
        text: "ID",
        dataIndex: 'ID',
        width: 50
    }],
    bbar: Ext.create('Ext.PagingToolbar', {
        store: store,
        displayInfo: true,
        displayMsg: 'Exibindo {0} - {1} de {2}',
        emptyMsg: "Nenhum pedido"
    }),
    renderTo: 'pedidos'
});

store.load({
    params: {
        start: 0,
        limit: 10
    }
});

and the function that set the new store

store.load({
    params: {
        param: newparam
    }
});

also, when I call this function, I would like to set the label on the viewing page x of y back to 1, since setting a new store takes you back to the first page

thanks again

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T12:13:34+00:00Added an answer on May 27, 2026 at 12:13 pm

    I am not sure why you are replacing the store when you page through your data..but notice the paging toolbar is bound to the store as well as the grid itself. If you are going to change the underlying store here you will need to rebind columns, and the paging bar. Try the reconfigure method http://docs.sencha.com/ext-js/4-0/#!/api/Ext.panel.Table-method-reconfigure

    Again I think you need to reevaluate your use case and perhaps think of a different way of accomplishing what you are doing.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have datagridview with paging enabled. But when I want to move from page
I currently have a table(/grid) of data that I can page, filter and sort.
I have a grid with paging toolbar at the bottom and a 'Load' button
I'm trying to page a table, and while I have paging already working, it
I have a paging worked with NHibernate: public IEnumerable<Answer> GetAnswers(int page, int pageSize) {
I have a simple UserControl for database paging, that uses a controller to perform
I have an ASP.NET GridView with paging enabled. The list of page indexes are
I'm having an issue with WebGrid paging; but first, here's some controller pseudo code:
I have a datagridview that is using paging, it works perfectly fine and I
I have a Telerik RadGrid. The initial DataSource that is bound to the grid

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.