Decimal Digits in NumericTextBox control

21 Jul 20211 minute to read

Set Maximum Number of Decimal Digits

The maximum number of digits to be displayed after the decimal point can be specified by using the MaximumNumberDecimalDigits property.

NOTE

The MaximumNumberDecimalDigits property can be provided with positive value only.

numericTextBox.MaximumNumberDecimalDigits=2;

Display the textbox value with maximum decimal digits

Remove Default Decimal Digits in Xamarin Numeric Entry

Based on the MaximumNumberDecimalDigits property, the default number of decimal digits is displayed. By disabling the AllowDefaultDecimalDigits Boolean property, those default digits can be removed from the numeric entry view.

numericTextBox.AllowDefaultDecimalDigits = false;

Display the textbox value without default decimal digits