format.CurrencyFormatter

Object Description

The object that formats the number to currency string.

Supported Script Types

Client and server scripts

For more information, see SuiteScript 2.x Script Types.

Module

N/format/i18n Module

Methods and Properties

N/format/i18n Module Members

Since

2019.2

Syntax

Important:

The following code snippet shows the syntax for this member. It is not a functional example. For a complete script example, see N/format/i18n Module Script Samples.

            // Add additional code
...
var curFormatter = format.getCurrencyFormatter({
    currency: format.Currency.USD
});
// curFormatter is '{"currency":"USD","locale":"en_US","symbol":"$","isPrefixSymbol":true,"numberFormatter":{"groupSeparator":",","decimalSeparator":".","precision":"2","minPrecision":null,"maxPrecision":null,"negativeNumberFormat":"BRACKETS","locale":"en_US"}}'
...
// Add additional code 

          

Related Topics

General Notices