Hungary: Online invoicing exchangeRate tag’s value must report currency exchange rate on Date of VAT register of the invoice

Applies to: Dynamics 365 for Finance and Operations

Problem description

Hungary: Online invoicing system - <exchangeRate> tag’s value must report currency exchange rate from the CurrencyCode of the invoice to CurrencyCode in the TaxCode of the first tax transaction of the invoice on Date of VAT register of the invoice

Hotfix information

To resolve the issue, you need to import the following or a higher version of the ER configurations from LCS shared asset library:

  • Invoices Communication Model.version.61.xml
  • RTIR Invoice Data (HU).version.61.29.xml
  • RTIR mapping.version.61.58.xml


Fix downloading instructions are here:

Fix description

This hotfix provides the following algorithm of exchange rate identification:


A = CurrencyCode of the invoice (forexample EUR or HUF)

B = CurrencyCode in the TaxCode ofthe first tax transaction of the invoice {it is supposed that all taxtransactions by the same invoice must have the same CurrencyCode in related taxcodes setup} (for example HUF)


IF A = B

THEN exchangeRate = “1

ELSE exchangeRate = Currencyexchange rate of the type defined as “Accounting currency exchange rate type” in the Ledger setup from A to B on the Date of VAT registerof the invoice


With thischange to avoid potential “INCORRECT_SUMMARY_DATA_INVOICE_VAT_AMOUNT_HUF”warning (p.206 of “Invoice Data Reporting, Description of the REST APIInterface & Developer’s Documentation”) which is described as following:

“Issues awarning if the output VAT amount in the aggregate invoice in the invoice’scurrency and the VAT amount in HUF do not correspond based on the exchangerates indicated in the line items. Calculation: in the case of currencyCode<>”HUF”, the VAT amount ineach line item (lineVatAmount) must be multiplied by the exchange rate value inthe line item (lineExchangeRate), and the total of these products amounts tothe invoice VAT amount in HUF (invoiceVatAmountHUF).  Tolerated deviation: 1% of theinvoiceVatAmountHUF element, but at least 1 unit.”

calculationof the following tags’ values is also changed respectively:

- <lineVatAmountHUF>is calculated as <lineVatAmount> multiplied by exchangeRate

- <vatRateVatAmountHUF>is calculated as <vatRateVatAmount> multiplied by exchangeRate

- <invoiceVatAmountHUF>is calculated as <invoiceVatAmount> multiplied by exchangeRate

Be aware:reported values in <lineVatAmountHUF>, <vatRateVatAmountHUF>, <invoiceVatAmountHUF>tags may differ from the values stored in the tax transactions in some cases dueto following reasons:

-         Exchangerate on transaction date and exchange rate on Date of VAT register aredifferent.

-         Accountingcurrency and currency defined for the sates tax code are different andtriangulation exchange rate (which used on posting: document currency >accounting currency > tax code currency) on posting moment may differ fromthe exchange rate from document currency to tax code currency on Date of VATregister.

These aspectsshould be under user control and may require corrective tax transactions.