OnNeedDataSource not fired on page index change

2 posts, 0 answers
  1. kiwo
    kiwo avatar
    17 posts
    Member since:
    Apr 2007

    Posted 14 May 2009 Link to this post

    Hi.

    I'm having a problem with making a grid paging work. I have a page with tree on the left + grid on the right. I use the tree selection to setup the data source for grid, and bind it programmatically. Then, when user wants to see the next page of the grid, I expect the grid to fire OnNeedDataSource event to ask for new data.

    The problem is the event is not fired. It IS fired when I change the page size, but IS NOT fired when I click "next page" button - and the grid becomes empty. Seems weird to me, and I'm stuck... Can you think of any things to be checked? What's the difference between page size and page index changes?

    Many thanks in advance!
  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 15 May 2009 Link to this post

    Hello Kiwo,

    Check if you are using the DataBind() method to bind your grid? If so, you should be using the AdvancedDataBinding techniques so that paging functions properly. if this does not help, try pasting your code here.

    Thanks
    Princy.
Back to Top