Radgrid loading takes too long - Ajaxifying Radgrid

2 posts, 0 answers
  1. Agm
    Agm avatar
    26 posts
    Member since:
    Sep 2012

    Posted 15 Apr 2014 Link to this post

    Hi,

    I am having Radgrid in a div (div1) and other controls in another div (div2) on toggle (hide/show) based structure.

    I want to show the div2 initially. problem is page is rendering after completion of Radgrid databind only.

    I want to load the data to Radgrid without taking too long. may be ajaxifying the load.

    Is it possible to show the controls in div2 before completing data loading of Radgrid??

    Thanking you,

    AGM RAJA
  2. Jayesh Goyani
    Jayesh Goyani avatar
    2732 posts
    Member since:
    May 2010

    Posted 16 Apr 2014 in reply to Agm Link to this post

    Hello,

    You can achieve this thing either by using client side or by using server side data binding.

    Client side

    http://demos.telerik.com/aspnet-ajax/grid/examples/data-binding/client-side/programmatic/defaultcs.aspx

    Bind one grid in page load event.
    For second grid binding
        1. you can either use settimeout()
         2. On success/complete/prerender event of first grid. (Please check client events of RadGrid for more information)

    Server side

    1. If you use RadAjaxManager then inside function call the Ajaxmanager's Ajaxrequest() (for binding the second grid). (If needed then set queuesize="50" in RadAjaxManager).
    2. if you use UpdatePanel then inside function call the __dopostback() of any/dummy button and set this/dummy button's visibility/display false so it will not displayed in the UI. (Please add this/dummy button inside update panel).

    When to call above JS function

    1. By using page prerender event of web page. (to call client side function from C#, please use RegisterStartUpScript).
    2. By using JS settimeout()

    http://demos.telerik.com/aspnet-ajax/ajax/examples/manager/clientsideapi/defaultcs.aspx

    Let me know if any concern.

    Thanks.
    Jayesh Goyani
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top