TX Text Control .NET for WPF

ShowAllDecimals Property

Property|Introduced in 16.0
Namespace
TXTextControl.WPF
Package
TXTextControl.TextControl.WPF.SDK as TXTextControl.WPF.dll from the private NuGet feed or Text Control Offline Packages

Description

Gets or sets a value specifying whether all decimals set with the Decimals property are shown, when the result is a string. If 3 decimals are set and the value is 15.5, the resulting string contains 15.500 when ShowAllDecimals is true and 15.5 when ShowAllDecimals is false. If the result is a double, this property has no meaning.

Syntax

public bool ShowAllDecimals { get; set; }

Examples

The following example uses MeasureConverter.ShowAllDecimals to configure show all decimals as part of the measure converter workflow. The configured value is checked before the workflow continues.

measureConverter.ShowAllDecimals = true;
if (measureConverter.ShowAllDecimals)
{
    Console.WriteLine("Measure Converter: Show All Decimals is enabled.");
}