How do I update the text of a label/control on my page when the user changes the value, using the OnValueChanged ClientEvent.
I have a Master/Content page scenario, with a RadAjaxManager in the master page and a RadAjaxManagerProxy in the content page. I also have my function in a RadCodeBlock and am using
to get the args. I can't get the numerictextbox to update the label's text when I change the value.
Here is my code block but neither line to set the text worked.
My textbox looks like this
I also tried adding those 2 controls, the textbox an the label to the updatedcontrols but that didn't help.
What am I missing here? Please help!
Aniket
I have a Master/Content page scenario, with a RadAjaxManager in the master page and a RadAjaxManagerProxy in the content page. I also have my function in a RadCodeBlock and am using
$find("<%= RadAjaxManager.GetCurrent(Page).ClientID %>").ajaxRequest("args"); |
to get the args. I can't get the numerictextbox to update the label's text when I change the value.
Here is my code block but neither line to set the text worked.
<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server"> |
<script language="javascript" type="text/javascript"> |
function OnClientValueChanged (sender, args) |
{ |
$find("<%= RadAjaxManager.GetCurrent(Page).ClientID %>").ajaxRequest("args"); |
<%= lblValueEntered.ClientID %>.Text= "Value Entered:" + args.get_newValue(); |
// document.getElementById("lblValueEntered").Text = "Value Entered:" + args.get_newValue(); |
} |
</script> |
</telerik:RadCodeBlock> |
My textbox looks like this
<div style="text-align: center; margin: 5px 0px 0px 5px;"> |
<asp:Label ID="lblScheduled" runat="server" Text="Lessons Scheduled" AssociatedControlID="txtScheduled"></asp:Label> |
<telerik:RadNumericTextBox ID="txtScheduled" runat="server" ShowSpinButtons="True" |
Culture="English (United States)" Width="125px"> |
<ClientEvents OnValueChanged="OnClientValueChanged" /> |
</telerik:RadNumericTextBox> |
</div> |
I also tried adding those 2 controls, the textbox an the label to the updatedcontrols but that didn't help.
What am I missing here? Please help!
Aniket