TX Text Control .NET Server

PDF Processing

Topic

Invoices sent to customers, contracts kept in an archive for decades, forms that come back filled in: many documents leave an application as PDF, and many arrive as PDF. TX Text Control .NET Server creates, converts and reads PDF documents on the server with ServerTextControl, without Adobe Acrobat or another PDF library. Beyond a first PDF, the tasks range from passwords and fonts to the PDF/A and PDF/UA standards, forms, attachments, metadata, watermarks, text extraction and validation.

The first PDF, an imported PDF and a signed PDF are built step by step in Getting Started: PDF Processing. Signing is described in depth in Digital Signatures.

How TX Text Control Handles PDF

PDF is an output and an input format of the same document engine:

  • Saving. A document that you create, load or merge is laid out in pages and saved with StreamType.AdobePDF, or with StreamType.AdobePDFA for archiving. Links, form fields and headers and footers become part of the PDF, and since version 34.0, every PDF carries the tagged structure that accessible documents need.
  • Loading. A PDF loaded with StreamType.AdobePDF becomes a document that TX Text Control reconstructs from the pages. Your code reads its text with positions, its metadata, its form field values and its embedded files. PDF/A is a format for saving only.
  • Where it runs. Text Control builds the PDF export itself. With the Core package TXTextControl.TextControl.Core.SDK, creating PDF documents works on Windows and Linux.

The settings for PDF documents are properties of SaveSettings and LoadSettings, which you pass to Save and Load. The elements of a document that end up in the PDF, such as tables, images or headers and footers, are described in Document Processing.

Find the Right Page

If you want toRead
Protect a PDF with passwords and permissions, run JavaScript when it opens or control its fontsPDF Creation
Convert DOCX, HTML, XLSX or Markdown to PDF, or PDF documents to editable formatsPDF Conversion
Create documents for long-term archiving and electronic invoicesPDF/A
Give a PDF a title, headings and descriptions for screen readersPDF/UA
Create interactive forms, import and export their data or flatten themPDF Forms
Embed files such as the XML of an electronic invoice and extract them againAttachments
Read the text of a PDF page by page, search it or read a value from an area of a pageText Extraction
Write and read the title, author, keywords and custom propertiesDocument Metadata
Put "DRAFT" or "CONFIDENTIAL" behind the text of every pageWatermarks
Check PDF documents against PDF/UA and stop documents that failPDF Validation
Sign PDF documents with a certificateDigital Signatures

Where to Start

  1. Getting Started: PDF Processing: a first PDF, if you haven't created one with TX Text Control yet.
  2. PDF Creation: what a PDF keeps from the document and how you protect it.
  3. PDF/A or PDF/UA, when your documents must meet a standard. A document can comply with both.
  4. PDF Validation: check the result before the documents leave your application.