HomeGuidesRecipesAPI
HomeGuidesAPILog In

Named Numeric Formats

When specifying common formats for numbers there are several named terms can be used. For example 'currency' could be used rather than '$0.00'. The terms are useful for the format function or document format property.

Usage

Format

Description

General Number

Display number with no thousand separator

Currency

Display number with a thousand separator, if appropriate; display two digits to the right of the decimal separator. The output is based on system locale settings.

Fixed

Display at least one digit to the left and two digits to the right of the decimal separator.

Standard

Display number with a thousand separator, at least one digit to the left and two digits to the right of the decimal separator.

Percent

Display number multiplied by 100 with a percent sign (%) appended to the right; always display two digits to the right of the decimal separator.

Scientific

Use standard scientific notation.

Yes/No

Display ‘No’ if the number is 0; otherwise, display ‘Yes’.

True/False

Display ’False’ if the number is 0; otherwise, display ‘True’.

On/Off

Display ‘Off’ if the number is 0; otherwise, display On’.