ScriptManager scriptManager = ScriptManager.GetCurrent(
this
.Page);
if
(scriptManager !=
null
)
{
Page.Form.Controls.Remove(scriptManager);
}
RadScriptManager radScriptManager =
new
RadScriptManager();
this
.Page.Form.Controls.AddAt(0, radScriptManager);
6 Answers, 1 is accepted

Check the following help documentation which explains how to add RadScriptManager.
RadScriptManager
Thanks,
Shinu.

Instead to add RadScriptManager from my web part I added RadScriptManager to Master page. After that I am getting the java script error "'length is null or not an object' in ScriptResource.axd Line:653" on every SharePoint page. I double checked <handlers> configuration and it looks fine. What is right approach to enable RadScriptManager on SharePoint 2010 site?
We have inspected the error that you described but we don't have a ready information about it. Would you please share more details what is the code that should be used in order to reproduce it locally?
You can also review this help topic where more information is provided in case you have missed something.
Hope this will be helpful.
Plamen
the Telerik team

I used the article "Create an AJAX-enabled SharePoint WebPart that uses RadControls" on my MOSS 2007 environment and it was working perfect but now I am creating smart web parts for SharePoint 2010 and this approach does not work. Ajax is enabled on SharePoint 2010 by default and ScriptManager is already placed in master page. My understending RadAjaxManager+LoadingPanel+RadGrid do not working with ScripManager I have to use RadScriptManager instead. If I simply replacing ScriptManager in master page on RadScriptManager I am getting java script error "'length is null or not an object' in ScriptResource.axd Line:653" on every SharePoint page. My question is how to configure RadScriptManager on SharePoint 2010? I was using RadAjax controls on MOSS 2007 and in ASP.NET applications without any issues. My issue is just with SharePoint 2010.
<
telerik:RadScriptManager
ID
=
"rsmFileUpload"
runat
=
"server"
>
</
telerik:RadScriptManager
>
<
telerik:RadAjaxManager
ID
=
"ramFileUpload"
runat
=
"server"
>
<
AjaxSettings
>
<
telerik:AjaxSetting
AjaxControlID
=
"btnAdd"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"rgDocuments"
LoadingPanelID
=
"panelProcessing"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
</
AjaxSettings
>
</
telerik:RadAjaxManager
>
<
telerik:RadAjaxLoadingPanel
ID
=
"panelProcessing"
runat
=
"server"
>
</
telerik:RadAjaxLoadingPanel
>
I have investigated the issue deeper. First of all I would like to clarify that all RadControls (including RadAjaxManager+LoadingPanel+RadGrid ) can work with ScriptManager and do not need replacing with RadScriptManager at all. The unusual behavior you are experiencing is most probably caused by a known issue in SharePoint where SP 2010 was failing to load scripts on an ajax request. That is why I will recommend you to upgrade to the latest cumulative update of the SharePoint 2010 server - it came out at the end of October. The cumulative pack contained a fix for the issue
Hope this will be helpful.
Plamen
the Telerik team

I just restored out of box Master page with ScriptManager and all my error were gone. Looks like the issue was in RadScripManager in master page.