Linking expenses to eDocuments in Expense Management
In countries where eInvoicing is mandated, purchases made by employees are sent as structured electronic documents (eDocuments) to Continia Expense Management, before the employee opens an expense form. When that happens, two records describe the same purchase: an eDocument processed by Continia Document Capture, and an expense submitted by the employee through Continia Expense Management. Without a connection between the two records, they are not correlated, which can cause double-posting.
The eDocument integration between Expense Management and Document Capture solves this by linking the two documents together. After an expense is linked to an eDocument, Document Capture handles the purchase posting side, and Expense Management posts the payment or reimbursement. This results in consistent ledger entries and a consistent set of dimensions on all related G/L entries.
Hinweis
eDocuments, when imported into Document Capture will create Document Capture Documents.
Prerequisites
This feature requires Continia Document Capture to be installed and active in your company. The integration has no effect in companies where Document Capture is not enabled.
How the link between an expense and an eDocument works
The connection between an expense and an eDocument is stored in two places at the same time:
- On the expense - the Applied Purch. Doc. Type field is set to Document Capture Document, and the Applied Purch. Doc. No. field holds the reference to the specific eDocument.
- On the eDocument - the Expense Entry No. field holds the reference back to the expense.
The two documents link when the user opens the expense and sets the Applied Purch. Doc. No. field to the relevant Document Capture Document.
If the eDocument carries a structured identifier (for example, a KSeF number in Poland or a FatturaPA SDI identifier in Italy), the user can store the identifier in the eDocument Id field on the expense.
How duplicate detection works
Even before a user links the two records manually, Expense Management and Document Capture are looking for matches. Duplicate detection runs in both directions, using the same three criteria:
| Criterion | Match rule |
|---|---|
| Amount | The expense amount equals the eDocument amount including VAT. |
| Currency | The currency codes match. |
| Document date | The eDocument date falls within three days of the expense document date. |
When a match is found, both sides receive a message identifying the candidate.
Detection runs automatically at two points in the workflow:
- When an expense is validated - detection runs if the expense's payment type is configured to expect a Document Capture Document, or if the expense already has an eDocument Id value filled in.
- When a Document Capture Document is validated - detection runs if the document's template (or the eDocument) is configured to expect a matching expense.
These hints are advisory; Duplicate detection never blocks a Document Capture Document from being processed because many incoming Document Capture Documents are not expenses. The bookkeeper retains responsibility for deciding whether to pair the records or leave them separate.
Configuring pairing expectations
If you want toy configure warnings that flag unpaired documents on either side, then you can configure both modules to flag documents that haven't been paired yet:
- In Expense Management - you can set a payment type to require an eDocument. Any expense using that payment type then shows a warning until an eDocument is linked. This configuration is useful for corporate cards used in countries where eInvoicing is mandatory.
- In Document Capture - you can set a Continia Document Capture (CDC) Template to expect an expense. This means that thereafter, every eDocument captured by that template shows a warning until an expense is linked. You can also set this flag on individual Document Capture Documents in situations where only some documents from a given supplier become expense claims.
In both modules, the default behavior is a warning that doesn't block posting. If your compliance requirements are stricter, you can escalate the warnings to errors through the Message Center Setup page, which hard-blocks posting until the pairing is complete.
How posting behaves when documents are linked
After an expense is linked to a Document Capture Document, the posting flow changes. Regardless of which document is posted first, the expense doesn't post the purchase side of the transaction – Document Capture does.
If your setup is configured to do so, dimension corrections are added to the purchase document after both documents are posted, adjusting the purchase document with the dimensions from the expense.
How dimension corrections keep G/L entries aligned across both sides
An eDocument is often posted before the expense is finalized, which means the eDocument's G/L entries can initially carry no dimensions, or dimensions that don't yet reflect the employee's allocation choices. An optional dimension correction step runs automatically after the expense is posted.
To keep dimensions consistent across both sides, when the Correct eDocument Dimensions setting is enabled on the Expense Management Setup page, Expense Management runs a dimension correction against the Document Capture Document's G/L entries after the linked expense is posted. This correction uses the built-in Dimension Correction module in Microsoft Dynamics 365 Business Central and runs in a separate transaction after the expense has been posted. If for any reason, the correction fails, the expense and the Document Capture Document remain posted and valid – only the dimension alignment will require manual intervention. If a dimension correction fails, you receive a notification.
You can review the correction history from the CDC Document Card via History of Dimension Corrections, which becomes available after a correction is applied.