# Document Processing

> Load and save XLSX, ODS, TXWB, PDF, CSV, XML and JSON, check Excel compatibility, set metadata and run the .NET and Node.js server packages in backend services.

- **Product:** TX Sheet Control
- **Section:** Documentation
- **Kind:** Topic
- **Path:** TX Sheet Control > Document Processing
- **1429 words**
- **Web URL:** https://docs.textcontrol.com/tx-sheet-control/document-processing/
- **LLMs URL:** https://docs.textcontrol.com/tx-sheet-control/document-processing/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-sheet-control/document-processing/llms-full.txt

---

Document processing turns files into workbooks and workbooks into files. TX Sheet Control reads XLSX, ODS and TXWB, updates cells and formulas, merges JSON into templates and saves XLSX, ODS, TXWB or PDF. One worksheet can also be exchanged as UTF-8 CSV, tabular XML or JSON records and rows.

You do this in the browser editor or on a server, where the .NET and Node.js server packages operate independently of the browser editor. Find out how loading and saving works and what an exchange with Excel keeps. For a backend service, see how to run, scale and measure processing.

### How It Works

- **One dispatcher for every format.** `load` and `save`, and in .NET `LoadAsync`, `LoadTextAsync`, `SaveAsync` and `SaveTextAsync`, take a stream type that selects the format: `SpreadsheetML` for XLSX, `InternalWorkbookFormat` for TXWB, `PDF`, `CSV`, `XML` and `JSON`. A filename extension alone does not select the format.
- **Workbooks or values.** XLSX exchanges spreadsheet documents with Excel-compatible applications. TXWB retains TX Sheet Control views, dashboards and report metadata. PDF delivers fixed-page output that cannot be loaded again. CSV, XML and JSON transfer the values of one worksheet, not workbook features.
- **Owners and handles.** Each mutable document has an owner: the browser editor or a backend control. Loading replaces the document and invalidates old handles, so you reacquire sheets and ranges after a load.
- **Browser or server.** The browser editor loads and saves in the browser, without a server round trip for tabular data. The .NET package `TXTextControl.TXSheetControl.Server` and the Node.js package `@txtextcontrol/tx-sheet-control-server` create reports without a browser.

### Choose Where Documents Are Processed

Editing and exporting in the editor happen in the browser, in the application page. Backend processing belongs to a .NET or Node.js service or console application. Use a backend when documents must be:

- Generated on a schedule
- Processed without a browser
- Combined with data that must remain on the server

Give unrelated users and jobs separate document instances or deliberately managed sessions. Authentication, authorization, storage, request limits and application data retrieval belong to the host application.

### Design a Predictable Pipeline

1. Load a trusted template or validate an uploaded file.
2. Resolve the worksheet and the ranges to update.
3. Apply values, formulas, formatting or mail merge.
4. Check the warnings and the business totals.
5. Export the required format and deliver the bytes.
6. Release the control or document when finished.

Three rules apply to the pipeline:

- **Editor initialization.** Await the initialization of the editor before font-sensitive work.
- **Backend tasks and promises.** Await every backend task or promise before you use its result or dispose its owner.
- **Handles.** Loading replaces document identities, so reacquire your handles after a load.

### Find the Right Page

| If you want to | Read |
|---|---|
| Load and save XLSX, ODS, TXWB and PDF, get text output and deliver the bytes | [Loading and Saving Workbooks](https://docs.textcontrol.com/tx-sheet-control/document-processing/load-save/llms-full.txt) |
| Import and export one worksheet as CSV, XML or JSON, with delimiters, schemas and limits | [CSV, XML and JSON Data](https://docs.textcontrol.com/tx-sheet-control/document-processing/tabular-data/llms-full.txt) |
| Validate what an XLSX exchange keeps and choose between XLSX, ODS, TXWB and PDF | [XLSX Compatibility](https://docs.textcontrol.com/tx-sheet-control/document-processing/xlsx-compatibility/llms-full.txt) |
| Set the title, author and other metadata of exported documents | [Document Properties](https://docs.textcontrol.com/tx-sheet-control/document-processing/properties/llms-full.txt) |
| Supply fonts with a document or embed the used fonts in the saved file | [Fonts in Documents](https://docs.textcontrol.com/tx-sheet-control/document-processing/document-fonts/llms-full.txt) |
| Create reports in a .NET or Node.js backend and return them as an HTTP response | [Backend Services](https://docs.textcontrol.com/tx-sheet-control/document-processing/backend-services/llms-full.txt) |
| Create and dispose controls, bound parallel requests and group changes in batches | [Lifetime and Concurrency](https://docs.textcontrol.com/tx-sheet-control/document-processing/lifetime/llms-full.txt) |
| Benchmark loading and export and calculate throughput | [Measuring Performance](https://docs.textcontrol.com/tx-sheet-control/document-processing/performance/llms-full.txt) |
| Merge JSON records into a workbook template | [Mail Merge](https://docs.textcontrol.com/tx-sheet-control/mail-merge/llms-full.txt) |
| Prepare print settings and export worksheets to PDF | [PDF Export](https://docs.textcontrol.com/tx-sheet-control/pdf/llms-full.txt) |

### Where to Start

1. [Loading and Saving Workbooks](https://docs.textcontrol.com/tx-sheet-control/document-processing/load-save/llms-full.txt): the formats, the stream types and the handling of failures.
2. [XLSX Compatibility](https://docs.textcontrol.com/tx-sheet-control/document-processing/xlsx-compatibility/llms-full.txt): validate a representative document before you rely on a conversion.
3. [Backend Services](https://docs.textcontrol.com/tx-sheet-control/document-processing/backend-services/llms-full.txt) and [Lifetime and Concurrency](https://docs.textcontrol.com/tx-sheet-control/document-processing/lifetime/llms-full.txt), when you process workbooks on a server.

If you haven't processed a workbook on a server yet, build a first job with [.NET](https://docs.textcontrol.com/tx-sheet-control/getting-started/document-processing/dotnet/llms-full.txt) or [Node.js](https://docs.textcontrol.com/tx-sheet-control/getting-started/document-processing/nodejs/llms-full.txt) in Getting Started.

### Pages in This Section

- [Loading and Saving Workbooks](https://docs.textcontrol.com/tx-sheet-control/document-processing/load-save/llms-full.txt): the seven formats and their stream types, loading and saving, string output, delivering the bytes, options and failures.
- [CSV, XML and JSON Data](https://docs.textcontrol.com/tx-sheet-control/document-processing/tabular-data/llms-full.txt): tabular import and export in JavaScript, TypeScript, ASP.NET Core, Angular, Node.js and .NET, with conventions and limits.
- [XLSX Compatibility](https://docs.textcontrol.com/tx-sheet-control/document-processing/xlsx-compatibility/llms-full.txt): conversion warnings, a representative test document, round trips and the choice of format.
- [Document Properties](https://docs.textcontrol.com/tx-sheet-control/document-processing/properties/llms-full.txt): the metadata of exported documents, inherited template metadata and the differences between formats.
- [Backend Services](https://docs.textcontrol.com/tx-sheet-control/document-processing/backend-services/llms-full.txt): the request flow, HTTP responses, pooling, application data and deployment checks.
- [Lifetime and Concurrency](https://docs.textcontrol.com/tx-sheet-control/document-processing/lifetime/llms-full.txt): owners of documents, disposal, sessions, bounded concurrency, batches and recovery from errors.
- [Measuring Performance](https://docs.textcontrol.com/tx-sheet-control/document-processing/performance/llms-full.txt): scenarios, measurements, throughput, warmup, the .NET benchmark sample and the interpretation of results.
- [OpenDocument Spreadsheet](https://docs.textcontrol.com/tx-sheet-control/document-processing/ods/llms-full.txt): load, edit and save ODS with original-package preservation.
- [Fonts in Documents](https://docs.textcontrol.com/tx-sheet-control/document-processing/document-fonts/llms-full.txt): fonts supplied with a document, font substitutions and embedded fonts in saved files.

---

## In This Section

- [Backend Services](https://docs.textcontrol.com/tx-sheet-control/document-processing/backend-services/llms-full.txt): Create reports without a browser in .NET and Node.js: the request flow, PDF responses in ASP.NET Core, pooled controls, application data and deployment checks.
- [Fonts in Documents](https://docs.textcontrol.com/tx-sheet-control/document-processing/document-fonts/llms-full.txt): Supply fonts with a TX Sheet Control document at load time, map font names with substitutions, and embed used fonts in TXWB, ODS and XLSX with embedUsedFonts.
- [Lifetime and Concurrency](https://docs.textcontrol.com/tx-sheet-control/document-processing/lifetime/llms-full.txt): Own editors and server controls correctly: ready and destroy, await using, sessions, bounded parallel requests, synchronous batches and recovery after errors.
- [Loading and Saving Workbooks](https://docs.textcontrol.com/tx-sheet-control/document-processing/load-save/llms-full.txt): Load and save XLSX, ODS, TXWB, PDF, CSV, XML and JSON with load, save and saveText: stream types, load warnings, string output, download of bytes and failures.
- [OpenDocument Spreadsheet](https://docs.textcontrol.com/tx-sheet-control/document-processing/ods/llms-full.txt): Load, edit and save ODS workbooks with TX Sheet Control in browser and server applications, using shared stream types and original-package preservation.
- [Measuring Performance](https://docs.textcontrol.com/tx-sheet-control/document-processing/performance/llms-full.txt): Measure browser zoom, XLSX loading and PDF export with realistic scenarios, visible cell counts, warmup, throughput and verified output.
- [Document Properties](https://docs.textcontrol.com/tx-sheet-control/document-processing/properties/llms-full.txt): Set title, author, keywords and company with DocumentProperties and DocumentExportOptions, review template metadata and verify XLSX, TXWB and PDF output.
- [CSV, XML and JSON Data](https://docs.textcontrol.com/tx-sheet-control/document-processing/tabular-data/llms-full.txt): Exchange one worksheet as CSV, tabular XML or JSON with load, save and saveText in JavaScript, TypeScript, Angular, Node.js and .NET: schemas and limits.
- [XLSX Compatibility](https://docs.textcontrol.com/tx-sheet-control/document-processing/xlsx-compatibility/llms-full.txt): Check XLSX import and export against Excel: conversion warnings, a representative test document, round trips and the choice between XLSX, TXWB and PDF.

---

## Nearby

- **Previous:** [Invoice Report Pipeline](https://docs.textcontrol.com/tx-sheet-control/mail-merge/report-pipeline/llms-full.txt)
- **Next:** [Loading and Saving Workbooks](https://docs.textcontrol.com/tx-sheet-control/document-processing/load-save/llms-full.txt)
