1. #1
    Sencha User
    Join Date
    Feb 2010
    Vote Rating
    vinodpadmanaban@gmail.com is on a distinguished road


    Default Grid Paging Toolbar problem


    I am getting paging issue when i delete the final record from last page, how can i resolve the paging issue, pls view the screen shot which i have attached.


    In Store save event(insert,update or delete) i will reload the store for update the grid for remote sort. like this

    firstGridreader= new Ext.data.JsonReader({ root: 'res', id: 'HJid', idProperty: 'DefIndex', totalProperty: 'totalCount', successProperty: 'success', messageProperty: 'message', fields: fields }), var fGridStore = new Ext.data.Store({
    autoLoad :false,
    baseParams:{start:0, limit:25},
    writer: fssuperGrdWriter,

    save :function ( St, records, options ){
    In Grid..
    bbar: new Ext.PagingToolbar({
    pageSize: 25,
    store: fGridStore,
    displayInfo: true,
    emptyMsg: "No records to display"
    if you view my screen shot.. 5 of 4 will be displayed .it happens when i delete the final record(or entire records) in last page after store reloads it show like 5 of 4 .
    total page is updated as 4 since there is only 4 pages but its staying in the 5 page

    how can i handle this problem or iam making any mistake or

    how can i move to the previous page when i delete the final record in the last page.

    Thanks in advance

  2. #2
    Sencha Premium Member lorezyra's Avatar
    Join Date
    Dec 2007
    Japan -- 日本
    Vote Rating
    lorezyra will become famous soon enough lorezyra will become famous soon enough



    Try this thread solution...


    Also, I would check the data for empty set and if true, move to the previous page...

    Look at PagingToolbar.movePrevious()
    Last edited by lorezyra; 17 Jan 2011 at 10:20 PM. Reason: More specfic to OP's question
    Perfection as a goal is a nice idea that can point one in a specific direction. However, since "perfection" is an ever changing (evolving?) and moving target, one must admit that perfection can never be obtained...

    When in doubt, check the d4mn source code!
    And here are my terms...
    1. I don't care if you use my source code. (Known as "Code.")
    2. I don't care if I get any monetary compensation.
    3. I do care to receive credit for Code provided. So, please keep my name in the comments for Code provided.
    4. Code is provided without warranty "AS-IS" and I claim absolutely no warranty nor liability to the quality, security, and run-ability on any platform.
    5. By using Code, you accept all risk inherit with Code regardless if Code has known and yet to be discovered bugs.
    6. You are welcome to change and improve the Code to best meet your needs.
    7. I don't care if you use the Code in a commercial or open-source project.
    8. You are not required to contact me prior to using the Code.
    Simple. Enjoy.

Similar Threads

  1. Problem with paging toolbar when grid is refreshed
    By salvin18 in forum Community Discussion
    Replies: 5
    Last Post: 30 Jul 2010, 12:54 AM
  2. Problem with Paging toolbar
    By maren in forum Ext 3.x: Help & Discussion
    Replies: 1
    Last Post: 11 Aug 2009, 4:18 AM
  3. paging toolbar problem
    By wicrosoft in forum Ext 2.x: Help & Discussion
    Replies: 5
    Last Post: 20 Oct 2008, 3:51 AM
  4. Paging toolbar problem
    By morange in forum Ext 2.x: Help & Discussion
    Replies: 0
    Last Post: 28 Jun 2008, 4:09 AM
  5. i have problem with Paging toolbar with grid panel
    By Jigesh Shah in forum Ext 2.x: Help & Discussion
    Replies: 2
    Last Post: 21 Apr 2008, 6:55 PM

Thread Participants: 1

Tags for this Thread