views:

28

answers:

2

Hi all,

I have some strange issues with loading of RadGrid. What I'm trying to accomplish is deferred loading user control from web service. This technique is explained on this link:

http://encosia.com/2008/02/05/boost-aspnet-performance-with-deferred-content-loading

In explorer and chrome works fine except, styling of a grid is not applied. In firefox, when I call web service from client side, I get blank screen and firebug shows error:

RadGridNamespace is not defined

any ideas?

A: 

It probably indicates RadGrid's scripts are not loaded on page by the time the grid object is initialized.

bugventure
yes, I think that is too..do you know how to init rad grid to initialize without those scripts or at least to loads them in the end?
Marko
The classic RadGrid for ASP.NET (using the **RadGridNamespace**) cannot function without its client scripts. What exactly are you trying to implement?
bugventure
nothing special..I am just loading serialized radgrid by calling web service witch prepare control, bind it, and then serialize it and returns to jquery...on return I put recieved control in div on page...but, page throws js error, as I explained above, and it is obviosly because of radgrid client side initialization took place after my scripts and not before as it should be...so, I need to somehow tell grid when to loads scripts or to turn them off..
Marko
All right. Can you modify the RadGrid markup after it's been rendered? If you can, search for any <script> tags inside and remove them from the markup. This way, you will not render any scripts that try to initialize the RadGrid client object.
bugventure
yes, that is the solution, dirty one, but the solution...I rather like to just turn it off or somehow control it's loading if I can...
Marko
A: 

Another thing is to get rid of the old Telerik ASP.NET grid and use its ASP.NET AJAX replacement. It is true ASP.NET AJAX control and supports declarative/programmatic client binding to web services as well as other cool client features.

Dick Lampard
Yes, especially for the scenario discussed in this topic, the RadGrid for ASP.NET AJAX (as well as all the other AJAX controls) provide the **RegisterWithScriptManager** property, which, when set to **false**, allows the control to be renderable outside the regular AJAX page lifecycle. Thus, you can easily render the control and send its HTML back from the AJAX request. Upgrading to [RadControls for ASP.NET AJAX][http://www.telerik.com/products/aspnet-ajax.aspx] is recommended for richer client and server capabilities.Plus, they see active improvement and support.
bugventure