currency() Function

Function

currency( number, decimals )

Converts a decimal number into a generic currency value by effectively adding a generic currency symbol (¤), a decimal point, and one comma for every three digits preceding the decimal.

Parameters

Keyword Type Description

number

Decimal

The number of currency units to be returned as text.

decimals

Decimal

The number of digits after the decimal to display. 2 by default.

Returns

Text

Usage considerations

If no arguments are passed, the generic currency symbol itself (¤) is returned as text.

Examples

currency(3213.43) returns ¤3,213.43

Open in Github Built: Wed, Aug 16, 2023 (04:37:39 PM)

On This Page

FEEDBACK