RadAjaxManagerProxy: 'id' of undefined

5 posts, 0 answers
  1. CARLOS
    CARLOS avatar
    4 posts
    Member since:
    May 2011

    Posted 01 Jun 2013 Link to this post

    I am probably missing something simple. I have a master page with the RadAjaxManager, I created a brand new content page and added the RadAjaxManagerProxy. I added a button and a label. When I click the button, I put the current date on the label. Simple

    <telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="Button_ClearFilters">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="Label_Today" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManagerProxy>
     
    <asp:Button ID="Button_ClearFilters" runat="server" Text="Clear filters" OnClick="Button_ClearFilters_Click"></asp:Button>
    <asp:Label ID="Label_Today" runat="server" Text="Today" />

    Yet for some reason, I am getting an error: 
    Uncaught TypeError: Cannot read property 'id' of undefined
    I would appreciate the help.
  2. CARLOS
    CARLOS avatar
    4 posts
    Member since:
    May 2011

    Posted 02 Jun 2013 Link to this post

    I found something odd. I made a brand new master page with RadAjaxManager and a content page with RadAjaxProxyManager1. I added the label and an asp.net button and a radbutton. Both should stamp the current date on the label. The radbutton worked. The asp button did not. Maybe someone at telerik can't tell me if this is expected. Thanks.

    <telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="Button1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="Label_Today" />
                </UpdatedControls>
            </telerik:AjaxSetting>
            <telerik:AjaxSetting AjaxControlID="RadButton1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="Label_Today" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManagerProxy>
     
    <telerik:RadButton ID="RadButton1" runat="server" Text="RadButton Test" OnClick="RadButton1_Click">
    </telerik:RadButton>
    <asp:Button ID="Button1" runat="server" Text="Button Test" OnClick="Button1_Click" >
    </asp:Button>
     
    <asp:Panel ID="Panel_Today" runat="server">
        <asp:Label ID="Label_Today" runat="server" Text="Today" />
    </asp:Panel>
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. msigman
    msigman avatar
    141 posts
    Member since:
    Apr 2008

    Posted 03 Jun 2013 Link to this post

    This sounds as though there is some JavaScript that is attempting to find an element which does not exist on the page after PostBack.  Do you have some custom JavaScript somewhere on your pages?
    Cannot read property 'id' of undefined
  5. CARLOS
    CARLOS avatar
    4 posts
    Member since:
    May 2011

    Posted 04 Jun 2013 Link to this post

    No msigman. I actually created a new master page and a new content page. No javascript was added.
  6. Eyup
    Admin
    Eyup avatar
    3015 posts

    Posted 06 Jun 2013 Link to this post

    Hi Carlos,

    I have prepared a sample RadGrid web site to test the described behavior. Can you please run the attached application and instruct me the exact steps to reproduce the issue?

    Regards,
    Eyup
    Telerik
    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 the blog feed now.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017