Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
110
Please help - igGrid Load on command
posted

I've found this example for "Load on Demand - loadTrigger: auto" at: https://www.igniteui.com/grid/load-on-demand.

In the link they bind the static datasource, Is there anyway to bind the custom dynamic datasource before grid auto trigger everytime? Like when I scrolling the grid then call my service to get the dynamic data then igGrid bind my dynamic data to the grid

Thank you.

Parents Reply
  • 23953
    Offline posted in reply to Rajesh Varade

    Hello Rajesh,

    Rajesh Varade said:
    Can you please let me know what gird events are fired after igGrid LoadOnDemand is triggered and completed?

    The LoadOnDemand events are described here:

    http://help.infragistics.com/jQuery/2013.2/ui.iggridloadondemand#events

    Rajesh Varade said:
    I am trying to catch iggridrowsrendered event after load on demand and not able to hit it.

    What is the code you're using?

    Rajesh Varade said:

    Can you please throw some light on this? 

    I am struggling to make SelectionPersistense.js work with load on demand. The restoreSelection() function of this .js file is tied with iggridrowrendered.

    I guess that you know that you first need to enable the selection persistence with the code like this:

    $(document).on("iggridrendered", "#grid1", function rendered (evt, ui) {
    sp = SelectionPersistence(ui.owner);
    sp.enableFiltering();
    });

    This code needs to be executed before the grid is initialized.

    The iggridrowsrendered event will be thrown only when the grid is created or data bound. When user presses the "Load more data" button the igGridLoadOnDemand.rowsRequesting and igGridLoadOnDemand.rowsRequested events are fired sequentially. 

    From what I see the SelectionPersistence code will work without the need for modifications.

    P.S.: About your previous post:

    Rajesh Varade said:

    I am still not able to trigger the LoadOnDemand.

    But when I execute filter feature for at least once, after that LoadOnDemand works fine. But for the first time it does not work.

    I was not able to reproduce the behavior you describe. Your code looks Ok except that the autoGenerateColumns = false, but there are no columns defined.

    Overall I'm not sure what you're trying to achieve, because your sample code shows one set of features, but then you're talking about a different set of features.

    Next time, please open a new thread, because this thread discussion was created for a different scenario from yours.

    Hope this helps,
    Martin Pavlov
    Infragistics, Inc. 

Children