This is a migrated thread and some comments may be shown as answers.

RadWindow AjaxUpdatedControl OnTextChanged Control Disappears

1 Answer 68 Views
Window
This is a migrated thread and some comments may be shown as answers.
Andrew
Top achievements
Rank 1
Andrew asked on 21 Jul 2017, 12:01 AM

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

 

 

 

1 Answer, 1 is accepted

Sort by
0
Vessy
Telerik team
answered on 25 Jul 2017, 03:57 PM
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.
Tags
Window
Asked by
Andrew
Top achievements
Rank 1
Answers by
Vessy
Telerik team
Share this question
or