JVCL Help:TJvCsvDataSet

From Project JEDI Wiki
Jump to navigationJump to search
JEDI Visual Component Library Help

Search in JVCL Help

 
Search in all projects
 

Class Hierarchy

TJvCustomCsvDataSet
TJvCsvDataSet
run\JvCsvData.pas

File:JvCsvDataSet.jpg

Summary

In-memory TDataSet component similar to TTable or ClientDataSet. You must configure the CsvFieldDef (string) property before using it, and a valid CsvFieldDef will define, among other things, the width of the string fields. Data longer than the width of a field will be truncated, just like in the old days with dBase datasets (TTable)..

run\JvCsvData.pas


Pascal

 run\JvCsvData.pas
 TJvCsvDataSet = class(TJvCustomCsvDataSet);


Description

  1. JVCLInfo

An in-memory TDataSet component similar to TTable but with optional saving to CSV file, and which, unlike using TTable in CSV mode, does not utilize the BDE, or any external database access layers to do its work.
Since this component inherits from TDataSet, you can use it with any standard VCL data aware components. Remember to link to a DataSource, before you can link this to any data aware controls!
This component inherits from TJvCustomCsvDataSet. See TJvCustomCsvDataSet for more internal details.
To Use TJvCsvDataSet, and any other component that you create that inherits from TJvCustomCsvDataSet you *must* first set up the important Property called CsvFieldDef.

Note that rather than editing the CsvFieldDef yourself, you should click on the property editor button ([...]) on the right side of the CsvFieldDef field, in the Object Inspector.

Here is a valid CsvFieldDef string:

FirstName:$100,LastName:$100,Address:$100

That defines three string-type fields, each which can store up to 100 characters. If you need more than 80 characters, you must specify it, because if you made the CsvFieldDef like this, it would mean 80 characters:

FirstName,LastName,Address


run\JvCsvData.pas


See Also

TJvCsvDataSet.CsvFieldDef

run\JvCsvData.pas


About

Navigation

run\JvCsvData.pas



Contribute to this help topic

This documentation wiki is based on the collaborative effort of Project JEDI users. Your edits are welcome in order to improve documentation quality: edit this page