I use NumericTextBoxFor
to show amount in my application.
I need to show 20 digits.
Can I accomplish it using NumericTextBoxFor
?
I've been trying "max", but kendo just give 16 digits.
@(Html.Kendo().NumericTextBoxFor(model => model.To)
.Max(999999999999999999) //just 16 digits
.Spinners(false)
)
I tried to set 88888888888888888888 but it shows me 88888888888888885248.
Since the actual logic takes place client side, you are most likely getting funny results because the maximum value you can store in a JavaScript Number is 9,007,199,254,740,992. After that, it is representing it as an exponent and losing precision.
I tried doing this max test on the Kendo web site, I did see the value you were talking about, but when you click in the input box it turns to 88888888888888890000, which makes sense if it is turning it into an exponent.
See this and this for more information.
Also an alternative to max value, you could also try a Kendo mask docs here