You should not nest AJAX settings and a RadAJaxPanel. Remove the RadAjaxPanel and see how it goes: http://www.telerik.com/help/aspnet-ajax/ajax-controls-in-ajaxpanel-and-ajaxsettings.html.
ASP control disappears when updated with ajax (telerik)
Question
I have an asp button "btn" and a label "lbl". When I click the button, the label's text should change but instead the label disappears. This is my aspx:
<form id="form1" runat="server">
<telerik:RadScriptManager ID="RadScriptManager1" runat="server">
<Scripts>
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js">
</asp:ScriptReference>
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js">
</asp:ScriptReference>
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js">
</asp:ScriptReference>
</Scripts>
</telerik:RadScriptManager>
<telerik:RadAjaxManager runat="server">
<AjaxSettings>
<telerik:AjaxSetting AjaxControlID="btn">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="lbl" UpdatePanelCssClass="" />
</UpdatedControls>
</telerik:AjaxSetting>
</AjaxSettings>
</telerik:RadAjaxManager>
<div>
<telerik:RadAjaxPanel runat="server" HorizontalAlign="NotSet" ID="pnl">
<asp:Button runat="server" Text="test" ID="btn" OnClick="btn_OnClick"/>
<asp:Label runat="server" Text="test" ID="lbl"></asp:Label>
</telerik:RadAjaxPanel>
</div>
</form>
And this is my code behind:
protected void btn_OnClick(object sender, EventArgs e)
{
lbl.Text = "test2";
}
I'm sure this should work.. maybe it is something related with the latest telerik dll (2014Q1) or am I missing something?
thanks in advance
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow