How to validate a PDF/A-3b ZUGFeRD invoice

In version 2018, Qoppa’s PDF library jPDFPreflight has added a new validation profile for PDF/A-3b ZUGFeRD invoice. Here is some sample code to validate that a PDF file is compliant with this sub-format: PDFPreflight pdfPreflight = new PDFPreflight("c:\\qoppa\\testData\\zugferd_invoice.pdf", null); PreflightResults results = pdfPreflight.verifyDocument(new PDFA_3_B_ZUGFeRD_Verification(), null); if (results.isSuccessful()) { System.out.println("PDF is compliant"); }PDFPreflight pdfPreflight = new […]

Read More

Extract XML invoice data file from ZUGFeRD PDF invoice

A ZUGFeRD invoice data is saved in xml format within a PDF document as a file attachment so that it can be programmatically parsed and processed. Qoppa’s PDF library jPDFProcess allows to extract the xml file. Here is some sample code to extract the ZUGFeRD xml file contained in a PDF and save it to […]

Read More

How to add a ZUGFeRD invoice to a PDF document in Java using jPDFProcess

As of v2017R1.04, Qoppa’s Java PDF library jPDFProcess supports adding an electronic invoice in ZUGFeRD format to a PDF document as an XML file attachment or embedded file. Sample Java program showing how to attach an XML ZUGFeRD invoice to a PDF document using jPDFProcess: // Load the PDF document PDFDocument pdfDoc = new PDFDocument […]

Read More