Table of Contents

Format Number

Block Group: Number Formatting
Icon:Format Number block icon

Returns a number or string based on defined formatting criteria.

If the input value's number of decimal places is greater than that of the specified format, the Format Number block rounds the value.

Note

If format is null, the default formatting is returned. This default formatting includes a thousands separator and all decimal places.

For information on using dataflow blocks, see Dataflow.

For accepted and excluded arguments of Number Formatting blocks, see Number Formatting.


Input/Output Properties

The following properties of the Format Number block can take input and give output.

input specifies the number to format.

format specifies a combination of number format patterns to use. For example, you can format the value to be displayed as "1,050.40" with this format string: "#,###.00".


Output Property

The following property of the Format Number block can give output but cannot take input.

output returns the number or formatted string.


Examples

The following image shows two examples of the Format Number block. The topmost Format Number block formats a decimal value so that the value appears as a percentage with a label. The bottommost Format Number block rounds a number to the tenths place and includes a comma for a thousands separator.

Format Number block examples