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

RadNumerictextbox with Jquery

1 Answer 162 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Abhi Shinde
Top achievements
Rank 1
Abhi Shinde asked on 23 Dec 2011, 03:39 PM
Hi,
I am trying to assign value to Radnumeric textbox from jquery on change() event of same textbox.  
But its not working fine. If i replace teleik textbox to asp textbox its working fine.

MyCode.aspx
<script type="text/javascript">
    $(document).ready(function() {
        $('#<%= txtAmount.ClientID %>').change(function() {
$('#<%= txtAmount.ClientID %>').val(123);
}
})
    });
</script>
 
 
<telerik:RadNumericTextBox ID="txtAmount" ShowSpinButtons="false" Type="Number" runat="server"
                    InvalidStyleDuration="100" Width="200">
                    <NumberFormat DecimalDigits="2" DecimalSeparator="." AllowRounding="true" KeepNotRoundedValue="False" />
                </telerik:RadNumericTextBox>

Please check and let me know.
Thanks,
Abhi

1 Answer, 1 is accepted

Sort by
0
Princy
Top achievements
Rank 2
answered on 08 Oct 2012, 06:05 AM
Hi,

Try the following JQuery to achieve your scenario.

JS:
<script type="text/javascript">
    $(document).ready(function () {
        $('#<%= txtAmount.ClientID %>').change(function () {
            $('#<%= txtAmount.ClientID %>').val(123);
        });
    });
</script>

Hope this helps.

Regards,
Princy.
Tags
General Discussions
Asked by
Abhi Shinde
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Share this question
or