RadnumericTextbox rounding issue

the code:

<telerik:RadNumericTextBox ShowSpinButtons="False"  DisplayText="Infinite" 
                  ID="MaximumAmount_tb" runat="server"  IncrementSettings-InterceptArrowKeys="true">
                <ClientEvents OnFocus="OnMAximumAmounttbFocus" />
                </telerik:RadNumericTextBox>

 function OnMAximumAmounttbFocus(sender, args) {
    //alert(sender.get_displayValue());
    if (sender.get_displayValue() == "Infinite") {
        sender.set_value("9,999,999,999,999.99999");

    }
    else
    {return false; }

}

I always get this number as a result of the focus: 1 billion why? and how can I fix my problem to display: 999999999999999.99999?

+5
source share
1 answer

The documentation ( http://www.telerik.com/help/aspnet-ajax/input-numerictextbox-basics.html ) says: "RadNumericTextBox does not support maximum and minimum values ​​with a larger value than +/- 2 ^ 46". - therefore, it can mainly contain about 14 significant digits. You are trying to set 18 significant digits, which is too much for this.

+6
source

All Articles