Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Catalog · How the catalog works
Anything · Lazarus or Delphi
Random projectRandom project

CSVUtils

A small Object-Pascal library for CSV (and the like) handling (read and write). Support for both RFC 4180 and other syntax rules.

View on GitHub

Member rating

No ratings yet.

Sign in to rate this project.

README

Comma-Separated Values (CSV) library for Delphi/FreePascal

A small object-pascal library for CSV (and the like) handling (read and write).

Features

  • Support for both RFC 4180 and other syntax rules
  • Any field separator (comma by default)
  • Any text enclosure qualifier (double-quotes by default) with escaping rules
  • Records ending with a field separator (optional)
  • Ignoring white spaces around fields (optional)
  • Line breaks inside a field
  • Ignoring empty lines (optional)
  • Ignoring commented lines (optional)
  • Variable field count on each record (optional)
  • Fixed field count for all records (optional)
  • Any field data type (variant)
  • Custom locale (optional)

Usage

Copy CSVUtils.pas and/or CSVUtils.Table.pas to your project folder, then add to your Delphi/FreePascal project file. Respect the license. Nothing else is required.

Automated test units are found in the test folder. No external testing library is required.

API documentation