Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
314
webNumericEdit is rounding numbers
posted

 the webNumeriEdit is rounding the the values to 2 decimal digits only. (i.e.: 112.1234567 -> 112.12). Does anybody have a clue how to fix this?

It may works when setting the value of MinDecimalPlaces but I would consider that as a work around and not a solution since it will add zeros even for integer numbers.

Parents
No Data
Reply
  • 24497
    Verified Answer
    posted

    All format related properties like pattern, decimal places, etc. are defined by current CultureInfo. If you want different format for a particular instance of editor, then you should use Culture property at visual design or NumberFormat at run time. There are should be samples related to custom cultures which came with installation. Below is example:

    System.Globalization.NumberFormatInfo nf = new System.Globalization.NumberFormatInfo();
    nf.NumberDecimalDigits = 10;
    this.WebNumEdit1.NumberFormat = nf;

Children