RadWindow AjaxUpdatedControl OnTextChanged Control Disappears

2 posts, 0 answers
  1. Andrew
    Andrew avatar
    19 posts
    Member since:
    Mar 2015

    Posted 20 Jul 2017 Link to this post

    Hi

    How can I stop the Label1 disappearing on OnTextChanged?

    <telerik:RadAjaxManager runat="server" ID="RadAjaxManager1">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="Textbox1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="Label1"/>
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>
     
    <telerik:RadWindowManager ID="RadWindowManager1" runat="server" EnableShadow="true">
        <Windows>
        <telerik:RadWindow ID="RadWindow1" runat="server">
            <ContentTemplate>
                <asp:Panel ID="Panel1" runat="server">
            <asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
            <telerik:RadTextBox runat="server" ID="Textbox1" OnTextChanged="Textbox1_TextChanged" AutoPostBack="True"></telerik:RadTextBox>
                </asp:Panel>
            </ContentTemplate>
        </telerik:RadWindow>
        </Windows>
    </telerik:RadWindowManager>
     
        protected void Textbox1_TextChanged(object sender, EventArgs e)
        {
            if (sender is RadTextBox)
            {
                RadTextBox tb = (RadTextBox)sender;
                string message = "<strong>OnTextChanged</strong> event fired: Value has changed to: <em>\"" + (sender as RadTextBox).Text + "\"</em>";
                Label1.Text = message;
            }
        }

     

     

    Thankyou

    Andy

     

     

     

  2. Vessy
    Admin
    Vessy avatar
    1932 posts

    Posted 25 Jul 2017 Link to this post

    Hi Andy,

    I tested the provided code but no label is disappearing on my side. Can you take a look at the video from my test and see whether I am leaving anything out?

    For convenience I am attaching my test page to this reply - are you facing the same problem with it?
    https://www.screencast.com/t/C8UikuG40s

    Regards,
    Vessy
    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top