DecimalFormatter DecimalFormatter DecimalFormatter DecimalFormatter DecimalFormatter Class

Definition

Formats and parses decimal numbers.

public : sealed class DecimalFormatter : INumberFormatter, INumberFormatter2, INumberFormatterOptions, INumberParser, INumberRounderOption, ISignedZeroOption, ISignificantDigitsOption
struct winrt::Windows::Globalization::NumberFormatting::DecimalFormatter : INumberFormatter, INumberFormatter2, INumberFormatterOptions, INumberParser, INumberRounderOption, ISignedZeroOption, ISignificantDigitsOption
public sealed class DecimalFormatter : INumberFormatter, INumberFormatter2, INumberFormatterOptions, INumberParser, INumberRounderOption, ISignedZeroOption, ISignificantDigitsOption
Public NotInheritable Class DecimalFormatter Implements INumberFormatter, INumberFormatter2, INumberFormatterOptions, INumberParser, INumberRounderOption, ISignedZeroOption, ISignificantDigitsOption
var decimalFormatter = new decimalFormatter();
Attributes
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)

Remarks

If your app passes language tags used in this class to any National Language Support functions, it must first convert the tags by calling ResolveLocaleName.

Constructors

DecimalFormatter() DecimalFormatter() DecimalFormatter() DecimalFormatter() DecimalFormatter()

Creates a DecimalFormatter object and initializes it to default values.

DecimalFormatter(IIterable<String>, String) DecimalFormatter(IIterable<String>, String) DecimalFormatter(IIterable<String>, String) DecimalFormatter(IIterable<String>, String) DecimalFormatter(IIterable<String>, String)

Creates a DecimalFormatter object initialized by a language list and a geographic region.

Properties

FractionDigits FractionDigits FractionDigits FractionDigits FractionDigits

Gets or sets the minimum number of digits to display for the fraction part of the number.

GeographicRegion GeographicRegion GeographicRegion GeographicRegion GeographicRegion

Gets the region that is used when formatting and parsing decimal numbers.

IntegerDigits IntegerDigits IntegerDigits IntegerDigits IntegerDigits

Gets or sets the minimum number of digits to display for the integer part of the number.

IsDecimalPointAlwaysDisplayed IsDecimalPointAlwaysDisplayed IsDecimalPointAlwaysDisplayed IsDecimalPointAlwaysDisplayed IsDecimalPointAlwaysDisplayed

Gets or sets whether the decimal point of the number should always be displayed.

IsGrouped IsGrouped IsGrouped IsGrouped IsGrouped

Gets or sets whether the integer part of the number should be grouped.

IsZeroSigned IsZeroSigned IsZeroSigned IsZeroSigned IsZeroSigned

Gets or sets whether -0 is formatted as "-0" or "0".

Languages Languages Languages Languages Languages

Gets the priority list of language identifiers that is used when formatting and parsing decimal numbers.

NumberRounder NumberRounder NumberRounder NumberRounder NumberRounder

Gets or sets the current rounding strategy to be used when formatting numbers.

NumeralSystem NumeralSystem NumeralSystem NumeralSystem NumeralSystem

Gets or sets the numbering system that is used to format and parse decimal numbers.

ResolvedGeographicRegion ResolvedGeographicRegion ResolvedGeographicRegion ResolvedGeographicRegion ResolvedGeographicRegion

Gets the geographic region that was most recently used to format or parse decimal values.

ResolvedLanguage ResolvedLanguage ResolvedLanguage ResolvedLanguage ResolvedLanguage

Gets the language that was most recently used to format or parse decimal values.

SignificantDigits SignificantDigits SignificantDigits SignificantDigits SignificantDigits

Gets or sets the current padding to significant digits when a decimal number is formatted.

Methods

Format(Double) Format(Double) Format(Double) Format(Double) Format(Double)

Returns a string representation of a Double number.

Format(Int64) Format(Int64) Format(Int64) Format(Int64) Format(Int64)

Returns a string representation of an Int64 number.

Format(UInt64) Format(UInt64) Format(UInt64) Format(UInt64) Format(UInt64)

Returns a string representation of a UInt64 number.

FormatDouble(Double) FormatDouble(Double) FormatDouble(Double) FormatDouble(Double) FormatDouble(Double)

Returns a string representation of a Double number.

FormatInt(Int64) FormatInt(Int64) FormatInt(Int64) FormatInt(Int64) FormatInt(Int64)

Returns a string representation of an Int64 number.

FormatUInt(UInt64) FormatUInt(UInt64) FormatUInt(UInt64) FormatUInt(UInt64) FormatUInt(UInt64)

Returns a string representation of a UInt64 number.

ParseDouble(String) ParseDouble(String) ParseDouble(String) ParseDouble(String) ParseDouble(String)

Attempts to parse a string representation of a Double number.

ParseInt(String) ParseInt(String) ParseInt(String) ParseInt(String) ParseInt(String)

Attempts to parse a string representation of an integer.

ParseUInt(String) ParseUInt(String) ParseUInt(String) ParseUInt(String) ParseUInt(String)

Attempts to parse a string representation of an unsigned integer.

See Also