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

[Solved] OnValueChanged Client script

2 Answers 176 Views
Input
This is a migrated thread and some comments may be shown as answers.
Yamil
Top achievements
Rank 1
Yamil asked on 09 May 2008, 09:28 PM
Hi. I have this code in an ascx (froma radGrid i edited the values using a user control)

<telerik:RadNumericTextBox ID="txtCantidad" runat="server"   
                           MinValue="0" ShowSpinButtons="True"   
                           Width="80px" Height="16px" Value="1">  
     <ClientEvents  OnValueChanged="txtCantidadOnValueChanged" />                                                 
  <NumberFormat DecimalDigits="0" /> 
</telerik:RadNumericTextBox> 
    

And my javascript function

<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">  
 <script type="text/javascript">  
 //-----------------------------------------------------  
 // Recalcula total del tratamiento  
 //-----------------------------------------------------  
 function txtCantidadOnValueChanged(sender, eventArgs)  
 {  
     if (eventArgs.get_newValue() > -1)  
     {  
        var txtMonto = $find("<%= txtMonto.ClientID %>");  
        var txtTotal = $find("<%= txtTotal.ClientID %>");  
                    
         txtTotal.set_value(eventArgs.get_newValue() * txtMonto.get_value());  
      }  
  }  
  </script>      
</telerik:RadCodeBlock> 

However i got "txtCantidadOnValueChanged" is undefined...

Any help...

2 Answers, 1 is accepted

Sort by
0
Yamil
Top achievements
Rank 1
answered on 13 May 2008, 12:10 AM
I solved it.
I have a script Manager in my parent form and I have a RadAjaxManager in the user control. I delete the RadAjaxManager.
However I would like to have a RadAjaxPanel to show the user somethin is happening in the form...
Is it possible without a RadAjaxManager ?
0
Yavor
Telerik team
answered on 13 May 2008, 05:39 AM
Hello Yamil,

To see more information on the requested functionality, refer to the following article.
I hope it helps.

Kind regards,
Yavor
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
Input
Asked by
Yamil
Top achievements
Rank 1
Answers by
Yamil
Top achievements
Rank 1
Yavor
Telerik team
Share this question
or