Multiple Currencies Examples
When you're working with custom lines in an account that has multiple accounting books or currencies, NetSuite automatically handles currency conversion in the following situations:
-
If the transaction currency is different from the accounting book currency where the GL impact posts, NetSuite converts standard lines to the base currency. Custom lines don't need conversion so NetSuite creates the custom lines using the base currency.
For example, if a transaction uses EURO, but the accounting book uses GBP, NetSuite converts from EURO to GBP when calculating the GL impact, based on the exchange rate in NetSuite or the one set on the transaction.
For more information, see Currency Management.
-
NetSuite maps custom lines from a primary accounting book to a secondary one, and the two accounting books use different currencies.
For example, if the primary accounting book uses USD and the secondary book uses GBP, and you use setCreditAmount(credit) to set a custom line on the primary book with setBookSpecific(bookSpecific) set to false.
NetSuite converts the amount from USD to GBP when it adds the custom line impact to the secondary book. For more information about how lines are mapped between primary and secondary accounting books in a Custom GL Lines plug-in implementation, see Custom GL Lines Plug-in Process Flow.
The currency NetSuite converts to depends on both the subsidiary and the accounting book currency. For example, a US company has two subsidiaries:
Subsidiary Name |
Secondary Book 1 Currency |
Secondary Book 2 Currency |
---|---|---|
United States |
USD |
GBP |
Canada |
CAD |
Euro |
Any GL impact posts to the secondary accounting books based on the currency for the subsidiary accounting book. The GL impact shows in the currency for the accounting book, not the one on the transaction line items.
Converting Currency in a Custom GL Lines Plug-in Implementation
In general, you don't need to manually convert currencies if you're using the amounts of standard lines posted to a transaction to calculate the values of custom lines. However, if you want to use hard-coded currency values or retrieve an amount for a custom line from somewhere other than a standard GL impact line, you need to manually convert the currency amounts.
To perform the conversion, complete the following steps:
-
Get the base currency. You can search for the base currency or get it from the accounting book record. See Find the Base Currency and Base Currency from Accounting Book Record.
-
Perform the conversion. Get the transaction-specific conversion rate from the accounting book record or use the nlapiExchangeRate API. See Transaction-Specific Exchange Rates or Convert Currencies with SuiteScript.
Related Topics
- Custom GL Lines Plug-in Example Code
- Classifications
- Custom GL Lines Plug-in Guidelines and Best Practices
- Error Messages for Custom GL Lines Plug-in
- Custom Lines on Reports and in Searches
- Accessing the Custom GL Lines Audit Log
- Reviewing Custom GL Lines Plug-in Executions
- Deleting a Custom GL Lines Plug-in Implementation