Sign in Join

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

Catalog · How the catalog works

Random project

TCSVDataSource

Delphi CSV parser

View on GitHub

Anyone may press Interesting, signed in or not. It helps others find this project.

Member rating

No ratings yet.

Sign in to rate this project.

README

TObject - TCSVDataSource

CSV parser for Delphi Free. Fields as String, Integer or Extended.

Usage:

pascal
  var Source: TCSVDataSource;

  Source := TCSVDataSource.Create;
  try
    Source.SetDelimiter(Char(59));
    Source.LoadFromFile(FileName);

    while not Source.Eof do
    begin

      ShowMessage(Source.FieldByNameAsString('CARDHOLDER'));

      Source.Next;
    end;
  finally
    Source.Free;
  end;
  end;