Delimiter

CsvDataLoadOptions.Delimiter property

Gets or sets the character to be used as a column delimiter.

public char Delimiter { get; set; }

Remarks

The default value is ‘,’ (comma).

Examples

Shows how to use CSV as a data source (string).

Document doc = new Document(MyDir + "Reporting engine template - CSV data destination.docx");

CsvDataLoadOptions loadOptions = new CsvDataLoadOptions(true);
loadOptions.Delimiter = ';';
loadOptions.CommentChar = '$';
loadOptions.HasHeaders = true;
loadOptions.QuoteChar = '"';

CsvDataSource dataSource = new CsvDataSource(MyDir + "List of people.csv", loadOptions);
BuildReport(doc, dataSource, "persons");

doc.Save(ArtifactsDir + "ReportingEngine.CsvDataString.docx");

See Also