reverseCalculationByMainCurrencyUnit(ExchangeRate, BigDecimal) method
Syntax
BigDecimal
reverseCalculationByMainCurrencyUnit
(
ExchangeRate
exchangeRate
,
BigDecimal
targetAmount
)
Parameters
-
exchangeRate –
the exchange rate to use
-
targetAmount –
the BigDecimal amount that is the intended result of a currency conversion
Returns
the required amount of the source currency to convert as BigDecimal
Usage
Performs a "reverse conversion", calculating the necessary amount of the source currency required to receive the specified amount of the target currency.
Note
that this method should NOT be used for a currency conversion in the other direction; it is intended to be used to calculate the "appropriate" source amount.
the required amount of the source currency to convert as BigDecimal
Created October 21, 2013. Send feedback on this help topic to Technical Publications:
pubs@sap.com