Automatically split and merge received PDFs
- 9 min.
“We sometimes receive PDFs that contain multiple invoices in a single file. Saving these as separate files is really fiddly and error-prone. It would be helpful if this could be automated.”
Ester, Accounts Payable at Cronus
Document Capture can be configured to automatically split and merge received PDFs during the document import step, so incoming invoices or other documents in the document journal are ready to be processed. These automated features can help your company with scenarios such as:
- Some of your vendors mail you physical copies of invoices and credit memos. You can feed these paper documents through a multi-page scanner to produce a single PDF file, instead of scanning each document separately before submitting it to Document Capture.
- A vendor emails you a combined PDF of all open documents, such as invoices and credit memos. You can submit this file to Document Capture without further adjustments.
- A vendor emails each invoice as a PDF, separately attaching any other related documents – such as contract details, sales conditions, or delivery notes. Document Capture can merge these separate PDFs into a single document for Business Central, keeping related documents together for registration, approval, and posting.
Scenario
Ester at Cronus receives a multi-page PDF that needs to be split into separate invoices. For another vendor, she needs to automatically merge a PDF invoice with the related sales conditions PDF.
Ester needs to:
- Receive and import the PDFs.
- Review how each invoice and document is created in the document journal.
- Show the settings that configure automatic splitting and merging of PDFs.
Configure automatic PDF splitting
You enable automatic PDF splitting from the relevant Document Category page.
- On the OCR Processing FastTab, enable the option Split PDFs Automatically.
- The additional settings are available for Split PDFs on…
- Blank Page - creates a document after each blank PDF page, that is, a page with fewer than 40 characters recognized by OCR.
- Source ID - creates a document each time a new source ID is identified, for example, for each vendor in a multi-page PDF including invoices from different vendors.
- Separator Fields - creates a document each time a specified field is identified with a new value. Often, this is used for identifying different invoice numbers within a multi-page PDF from the same vendor.
- Barcode - creates a document each time a specified barcode is recognized.
If you enable Separator Fields, you also need to specify on each source template which field or fields to use as document separators.
Nota
For purchase invoices, the master template enables Invoice No. as a document separator by default, and no other fields. However, there might be scenarios when you need to adjust this for individual vendor templates.
From the Document Category page:
- Open the Templates FastTab and use the Edit action for the relevant template line.
- On the Fields FastTab, select the relevant field and use the Edit action to open the Template Field Card.
- On the General FastTab, enable the option Use as Document Separator. You might need to use the Show more action to see this option on the FastTab.
Configure automatic PDF merging
Automatic PDF merging is configured on each source template, such as a vendor template. This gives you the ability to control when received PDFs are merged and when they are not, even when receiving from the same vendor. Read more in the learning unit about using variant templates for the same vendor.
From the document journal:
- Open the Template action menu and click the Template Card action.
- On the General FastTab, enable the option Merge from the same Email. You might need to use the Show more action to see this option on the FastTab.
More resources
- Splitting and Merging Documents (Continia Docs article)
- Using a network scanner to import documents (Continia Docs article)