PDF/A-1 Use of PDF 1.4

Hi,

One of our customers has a requisite that PDF/A-1 should be saved as PDF 1.4.
The actual Aspose PDF saves PDF/A-1 as PDF 1.7, there’s no choice of the PDF version it should save the document.
Adobe specification is not very clear about it, they only specify “PDF/A-1. The PDF/A format is based on the original PDF 1.4 version and it has two conformance levels for PDFs: PDF/A-1a conforms with Level An and meets all requirements in its specification.”
( source https://www.adobe.com/uk/acrobat/resources/document-files/pdf-types/pdf-a.html#:~:text=PDF%2FA-1.,all%20requirements%20in%20its%20specification. )
others like Library of Congress specify it’s a subtype of PDF 1.4 ( source PDF/A-1, PDF for Long-term Preservation, Use of PDF 1.4)
Could Aspose PDF save PDF/A-1 ( A1a or A1b ) documents as PDF 1.4 please ?

Thanks

@pnocera

Currently, Aspose.PDF does not provide an option to save PDF/A-1 documents specifically as PDF 1.4. The library typically saves PDF/A-1 documents in PDF 1.7 format. This behavior aligns with the general specifications of PDF/A-1, which is based on PDF 1.4, but the implementation in Aspose.PDF defaults to a later version.

To ensure compliance with PDF/A-1, you can validate your PDF document against the PDF/A-1a or PDF/A-1b standards using the Aspose.PDF library. Here’s a code snippet that demonstrates how to validate a PDF document for PDF/A compliance:

import com.aspose.pdf.Document;
import com.aspose.pdf.PdfFormat;

public class ValidatePDFDocumentForPDFAStandard {
    public static void main(String[] args) {
        // Open the document
        Document pdfDocument = new Document("Original.pdf");
        // Validate PDF for PDF/A-1b
        pdfDocument.validate("validation-result-A1B.xml", PdfFormat.PDF_A_1B);
        // Save the output document
        pdfDocument.save("Optimized_output.pdf");
    }
}

In this example, the document is validated for PDF/A-1b compliance, and the validation results are saved in an XML file. You can adjust the validation level as needed.

For further details on converting PDF files to PDF/A formats, you can refer to the official documentation, which outlines the supported standards and conversion methods available in Aspose.PDF here [1].

If you have specific requirements or further questions regarding PDF/A compliance, feel free to ask!

Sources:
[1]: Convert PDF to PDF/A formats - Aspose Documentation

We need PDF/A-1 ( A1a or A1b ) documents to be saved as PDF 1.4. This is a requirement.

@pnocera

We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): PDFNET-59477

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

@pnocera

The ISO 19005-1:2005 standard (PDF/A-1) doesn’t specify explicitly whether the conformant PDF document should be of some specific version, and later versions ISO 19005-2:2011 and ISO 19005-3:2012 (PDF/A-2 and PDF/A-3 respectively) clarify this and state explicitly that any version from PDF-1.0 up to PDF-1.7 included can be conformant to the standard. Therefore, it’s not necessary to save PDF/A-1 documents as PDF-1.4 only.

Still, if you need your documents to be saved under the specific version, this can be done manually, since the Aspose.PDF doesn’t change the initial document version on PDF/A conversion and saving the document. This may be done one of the following ways:

  • Pass the required version explicitly on document creation, fill the document, convert to PDF/A-1, and save:
// Specify the PDF version explicitly when the document is constructed.
using (Aspose.Pdf.Document document = new Aspose.Pdf.Document(Aspose.Pdf.PdfVersion.v_1_4))
{
    Aspose.Pdf.Page page = document.Pages.Add();

    Aspose.Pdf.Text.TextFragment text = new Aspose.Pdf.Text.TextFragment("Hello world!");
    page.Paragraphs.Add(text);

    // Convert the document to PDF/A-1b, the document version is preserved.
    document.Convert(Stream.Null, Aspose.Pdf.PdfFormat.PDF_A_1B, Aspose.Pdf.ConvertErrorAction.Delete);

    // Save the document, the document version is preserved.
    document.Save(outputPdf);
}
  • Convert an existing document to PDF-1.4 first, then convert to PDF/A-1, and save:
using (Aspose.Pdf.Document document = new Aspose.Pdf.Document(dataDir + "input.pdf"))
{
    // Convert the document to PDF-1.4.
    document.Convert(Stream.Null, Aspose.Pdf.PdfFormat.v_1_4, Aspose.Pdf.ConvertErrorAction.Delete);

    // Convert the document to PDF/A-1b, the document version is preserved.
    document.Convert(Stream.Null, Aspose.Pdf.PdfFormat.PDF_A_1B, Aspose.Pdf.ConvertErrorAction.Delete);

    // Save the document, the document version is preserved.
    document.Save(outputPdf);
}

Either way, the result document will have the PDF-1.4 version, as requested by the you.