ObviousPDF.Csv 1.5.0

dotnet add package ObviousPDF.Csv --version 1.5.0
                    
NuGet\Install-Package ObviousPDF.Csv -Version 1.5.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="ObviousPDF.Csv" Version="1.5.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="ObviousPDF.Csv" Version="1.5.0" />
                    
Directory.Packages.props
<PackageReference Include="ObviousPDF.Csv" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add ObviousPDF.Csv --version 1.5.0
                    
#r "nuget: ObviousPDF.Csv, 1.5.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package ObviousPDF.Csv@1.5.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=ObviousPDF.Csv&version=1.5.0
                    
Install as a Cake Addin
#tool nuget:?package=ObviousPDF.Csv&version=1.5.0
                    
Install as a Cake Tool

ObviousPDF.Csv

CSV-to-PDF renderer for the ObviousPDF library.

Overview

ObviousPDF.Csv accepts a CSV document conforming to the ObviousPDF CSV Format and produces a tagged, accessible PDF. It is a format peer of ObviousPDF.Json and ObviousPDF.Xml, sharing the same rendering pipeline and accessibility guarantees.

Quick Start

using ObviousPDF.Csv;

// Render from CSV string to file
PdfCsvRenderer.Render(csvString, "output.pdf");

// Render from CSV file to PDF file
PdfCsvRenderer.RenderFromFile("document.csv", "output.pdf");

// Validate without rendering
var validator = new PdfCsvValidator();
var result = validator.Validate(csvString);
if (!result.IsValid)
    Console.WriteLine(result);

// Generate a starter form template for users to fill in
var templateCsv = PdfCsvRenderer.CreateFormTemplate("Expense Reimbursement Form");
File.WriteAllText("expense-form-template.csv", templateCsv);

Form Template Generator

PdfCsvRenderer.CreateFormTemplate() creates a starter CSV file for form-based documents. The generated template includes:

  • [DOCUMENT] settings with accessibility defaults enabled
  • [FONTS] entries for common title and field text
  • A sample [PAGE 1] section with form field placeholders

Use the optional pageCount parameter to generate multiple sample page sections.

CSV Format

The ObviousPDF CSV format uses section headers to organize document structure:

[DOCUMENT]
coordinateOrigin,bottomLeft
language,en-US
tagged,true

[FONTS]
id,mode,standardFont,bundledFont,path,description,data
heading,bundled,,SerifBold,,Heading font,

[PAGE 1]
type,x,y,...,text,...,fontRef,fontSize,...
text,72,720,...,Hello World!,...,heading,24,...

Key Features

  • Section-based[DOCUMENT], [PAGE n], [FONTS], [IMAGES], [STRUCTURE], etc.
  • Spreadsheet-friendly — Designed for creation in Excel, Google Sheets, or LibreOffice Calc
  • Full accessibility — Tagged PDF, PDF/UA-1, structure tree, alt text

Make any CSV-to-PDF document fully accessible with a single line:

[DOCUMENT]
coordinateOrigin,topLeft
accessible,true
language,en-US
displayDocTitle,true
info.title,"My Document"

With accessible,true, the renderer automatically enables tagged PDF, PDF/UA-1 conformance, auto-tagging for text and images, standard font auto-upgrade, and correct form field structure placement. No manual structure tree is required.

Use the structureTag column to override the default <P> auto-tag:

text,160,28,,,,,,,U.S. Individual Income Tax Return,title-font,14,black,,,,,,,,,,,,,H1,,
text,36,90,,,,,,,Filing Status,section-font,10,white,,,,,,,,,,,,,H2,,

See the Form 1040 Easy Accessibility example for a complete 3-page IRS form with checkboxes, text fields, and dropdowns.

Sister Projects

Package Format Best For
ObviousPDF.Json JSON Web APIs, LLM/AI generation
ObviousPDF.Xml XML Enterprise workflows, XSLT transforms
ObviousPDF.Csv CSV Spreadsheet authoring (Excel, Google Sheets)

All three pipelines produce identical PDF output and share the same accessibility features.

  • Compact color syntaxrgb(0.2,0.4,0.8), gray(0.5), cmyk(...), #1A4C99, red
  • All content types — Text, images, graphics, form fields, annotations, transforms

Requirements

  • .NET 6.0, .NET 8.0, .NET 9.0, or .NET 10.0
  • ObviousPDF core package (referenced automatically)

License

See LICENSE.md for details.

Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.5.0 102 4/26/2026
1.4.0 100 4/12/2026