script control 'RadAjaxManager1" is not a registered script control.

9 posts, 1 answers
  1. Adam
    Adam avatar
    5 posts
    Member since:
    May 2011

    Posted 20 Jul 2011 Link to this post

    I am trying to place a radscheduler as a user control on one of my pages, I am getting this error

    script control 'RadAjaxManager1" is not a registered script control. Script controls must be registered using RegisterScriptControl() before calling RegisterScriptSescriptors. Parameter name: scriptControl.

    it's weird because when I run my code on my local machine everything is honky dory, but once I move it to the server it no longer works.

     any ideas on why this would be happening?

    <%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
            <%--//commentedout to seperate grid from scheduler
                <telerik:AjaxSetting AjaxControlID="RadGrid1">--%>
                <telerik:AjaxSetting AjaxControlID="RadScheduler3">
                    <%--//commentedout to seperate grid from scheduler
                        <telerik:AjaxUpdatedControl ControlID="RadGrid1" />--%>
                    <telerik:AjaxUpdatedControl ControlID="RadScheduler3" LoadingPanelID="RadAjaxLoadingPanel1" />
            <%--<telerik:AjaxSetting AjaxControlID="Panel1">
                            <telerik:AjaxUpdatedControl ControlID="RadScheduler3" LoadingPanelID="RadAjaxLoadingPanel1" />
                            <telerik:AjaxUpdatedControl ControlID="RadToolTipManager1" />

    <%--<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server">
     <asp:Label id="Label2" runat="server" ForeColor="Red">Loading... </asp:Label>
    </telerik:RadAjaxLoadingPanel> />

    <telerik:RadScheduler ID="RadScheduler3"
        StartEditingInAdvancedForm ="true"
        <Reminders Enabled="True" />


    Adam Pierce

  2. Answer
    Peter avatar
    6637 posts

    Posted 21 Jul 2011 Link to this post

    Hello Adam,

    The recommended practice is to put RadAjaxManager on your page or master page, and use RadAjaxManagerProxy in the user control.

    Best wishes, Peter
    the Telerik team

    Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

  3. Francesco
    Francesco avatar
    15 posts
    Member since:
    Jul 2011

    Posted 27 Jul 2011 Link to this post


    I'm getting the same javascript error while integrating a RadGrid in RadScheduler.

    I followed the advanced form customization guide (because my advanced form is more complex). I defined a custom user control in which there is a RadTabStrip with 3 tabs and inside one of them I integrated a RadGrid, with paging, sorting and filtering. The RadScheduler is defined in a user control that is the content of a masterpage, and it's ajaxified using RadAjaxManager (declared into masterpage but set using the Proxy inside the usercontrol). It is databound to a collection filled from a database, as well as the the DataTable bound to RadGrid.

    Here is some excerpt from Master and content page to show Ajax, ScriptManager and RadScheduler settings:

        <form id="form1" runat="server">
        <telerik:RadScriptManager ID="ScriptManager2" runat="server">
                <asp:ScriptReference Path="AdvancedForm.js" />
        <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"></telerik:RadAjaxManager>
        <asp:ContentPlaceHolder ID="PlaceHolder" runat="server" />

    Content page:
    <asp:Content ID="Content1" ContentPlaceHolderID="PlaceHolder" runat="server">
        <telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server">
                <telerik:AjaxSetting AjaxControlID="RadScheduler1">
                        <telerik:AjaxUpdatedControl ControlID="RadScheduler1" LoadingPanelID="RadAjaxLoadingPanel1" />
        <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" />
       <telerik:RadScheduler ID="RadScheduler1" runat="server" ... >
                    <AdvancedForm Modal="true" />
                        <scheduler:InlineInsertForm runat="server" ID="InlineInsertForm1" Mode="Insert" Subject='<%# Bind("Subject") %>'... />
                        <scheduler:AdvancedForm runat="server" ID="AdvancedInsertForm1" Mode="Insert" Subject='<%# Bind("Subject") %>' ...  />
                    <AdvancedForm EnableCustomAttributeEditing="True" />
                        <scheduler:AdvancedForm runat="server" ID="AdvancedEditForm1" Mode="Edit" Subject='<%# Bind("Subject") %>' ...  />

    Since every action which triggers a postback (in this case, sorting, changing page and filtering) causes the loss of the state of the advanced form (every field becomes empty), I wrapped the RadGrid in a RadAjaxPanel. Now any of that action gives me the javascript error "Script control 'rfltMenu' is not a registered script control. Script controls must be registered using RegisterScriptControl() before calling RegisterScriptDescriptors()." and if I remove filtering support, it gives me the same error on another grid component and so on.

    I read that the RegisterWithScriptManager attribute was introduced to handle these errors, I've set it to false and called the RegisterScriptControl() passing the RadGrid instance in the OnPreRender method of the AdvancedForm usercontrol, but to no avail.

    Here is some excerpt from the usercontrol:

    Excerpt from AdvancedForm.aspx:
    <telerik:RadAjaxPanel ID="contactsRefreshPanel" runat="server">
        <telerik:RadGrid AutoGenerateColumns="false" ID="ContactsGrid"
            AllowSorting="True" AllowFilteringByColumn="true"
            AllowPaging="True" PageSize="2"
            <PagerStyle Mode="NextPrevAndNumeric" />
            <MasterTableView AutoGenerateColumns="false" TableLayout="Auto">
                    <telerik:GridBoundColumn DataField="Name" HeaderText="Nome" SortExpression="Name"
                        UniqueName="Name" AutoPostBackOnFilter="true" CurrentFilterFunction="Contains" ShowFilterIcon="false">
                    <telerik:GridBoundColumn DataField="Surname" HeaderText="Cognome" SortExpression="Surname"
                        UniqueName="Surname" AutoPostBackOnFilter="true" CurrentFilterFunction="Contains" ShowFilterIcon="false">
                    <telerik:GridBoundColumn DataField="Company" HeaderText="Azienda" SortExpression="Company"
                        UniqueName="Company" AutoPostBackOnFilter="true" CurrentFilterFunction="Contains" ShowFilterIcon="false">
                    <telerik:GridBoundColumn DataField="Email" HeaderText="Email" SortExpression="Email"
                        UniqueName="Email" AutoPostBackOnFilter="true" CurrentFilterFunction="Contains" ShowFilterIcon="false">
                    <telerik:GridBoundColumn DataField="CellularPhone" HeaderText="Cellulare" SortExpression="CellularPhone"
                        UniqueName="CellularPhone" AutoPostBackOnFilter="true" CurrentFilterFunction="Contains" ShowFilterIcon="false">

    Excerpt from AdvancedForm.cs:
    public partial class AdvancedForm : System.Web.UI.UserControl
            protected void Page_Load(object sender, EventArgs e)
                UpdateButton.ValidationGroup = Owner.ValidationGroup;
                UpdateButton.CommandName = Mode == AdvancedFormMode.Edit ? "Update" : "Insert";
                // A series of client scripts registered
            protected void ContactsGrid_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
                ContactsGrid.DataSource = Default.GetDataTable("SELECT * FROM Contacts");
            protected override void OnPreRender(EventArgs e)
                if (!FormInitialized)
                    FormInitialized = true;
                if (!this.DesignMode)
                    // Test for ScriptManager and register if it exists
                    ScriptManager sm = ScriptManager.GetCurrent(Page);
                    if (sm == null)
                        throw new HttpException("A ScriptManager control must exist on the current page.");

    Perhaps there something in the Ajax settings which isn't correct? I tried many things, including using RadAjaxManagerProxy to ajaxify the grid only but without results.
    Any other suggestion is welcome. I'm stuck on this problem for 2 days.

    By the way, I'm using RadControls Q1 2011 SP2.

    Thanks in advance!
  4. Francesco
    Francesco avatar
    15 posts
    Member since:
    Jul 2011

    Posted 28 Jul 2011 Link to this post

    No one has any advice on what could be the cause of the error, or something to try to find it out?
    I'm stuck here and I need to deliver this part of the software next week, so I'm a little strict on time...

    Thank you!
  5. Francesco
    Francesco avatar
    15 posts
    Member since:
    Jul 2011
  6. Peter
    Peter avatar
    6637 posts

    Posted 02 Aug 2011 Link to this post

    Hi Francesco,

    I noticed that you have configured RadAjaxManagerProxy to ajaxify RadScheduler. In this case, all controls in the advanced form will also be ajaxified and there is no need to wrap RadGrid in an UpdatePanel.

    I did a sample using your code, but everything worked as expected. Please, test the attached demo and let me know what is different at your side.

    Greetings, Peter
    the Telerik team

    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

  7. Francesco
    Francesco avatar
    15 posts
    Member since:
    Jul 2011

    Posted 02 Aug 2011 Link to this post

    Thank you for your help, Peter. I tried this scenario on a clean demo of Customizing Advanced Form Template before and worked, just like your project, but in our project the same thing failed.
    We've already opened a ticket with the project attached and your team was able to reproduce the issue and solve it.

    There is another problem which emerged from the resolution of this, but it has nothing to do with Ajax settings so I consider this discussion closed.

    Thank you and your team for your support.
  8. Bex
    Bex avatar
    53 posts
    Member since:
    Jul 2011

    Posted 10 Oct 2012 Link to this post

    I am having a very similar problem.
    I know this is an old post but can anyone post what the problem was and how it was resolved?
  9. Plamen
    Plamen avatar
    2958 posts

    Posted 15 Oct 2012 Link to this post

    Hi Bex,

    You can refer to the recommended practices when RadAjaxManager is on your page or master page, and use RadAjaxManagerProxy in the user control. If you still can't figure out what is causing the issue please elaborate a little bit the exact scenario so we can be more helpful.

    All the best,
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Back to Top