Skip to main content
Version: Current

Write To CSV

Description

Writes data from a DataTable to a CSV file and returns a File Reference to the created or updated file.

The activity supports configurable delimiters, text encodings, optional column headers, and file overwrite or append behavior.


Common Capabilities

Process Data Support

info

This activity supports dynamic configuration using variables from the Process Data drawer.

You can bind values from Model Data, Form Data, System Data, Enterprise Variables, and Activity Outputs.

Learn more → Using Process Data


Design-Time Configuration

Display Text

The label for this activity as it appears on the workflow canvas.

Target Folder

A FolderReference identifying the destination folder where the CSV file will be created or updated.

File Name

The name of the CSV file.

The .csv extension is added automatically.

Supports Liquid expressions.

Data Table

The source DataTable whose rows will be written to the CSV file.

Delimiter

Specifies the character used to separate fields in the CSV file.

Supported values:

  • Comma (,)
  • Semicolon (;)
  • Tab
  • Pipe (|)

Encoding

Specifies the text encoding used when writing the file.

Supported values include:

  • UTF-8
  • UTF-16
  • UTF-16BE
  • ASCII
  • ISO-8859-1
  • Windows-1252

Include Column Names

Determines whether DataTable column names are written as the first row of the CSV file.

If File Exists

Determines how the activity behaves when the target file already exists.

Supported values:

  • Overwrite Existing Content – Replaces the existing file with the current DataTable contents.
  • Append Content – Appends DataTable rows to the end of the existing file.
note

When appending to an existing file, only data rows are appended. Column headers are not written again, even when Include Column Names is enabled.


Properties

Input

PropertyTypeDescription
Target FolderFolderReferenceDestination folder
File NameStringName of the CSV file
Data TableDataTableData to write
DelimiterStringField separator
EncodingStringText encoding
Include Column NamesBooleanWrites column names as the first row
If File ExistsStringControls overwrite or append behavior

Output

PropertyTypeDescription
FileFileReferenceReference to the CSV file that was created or updated
Total RowsIntegerNumber of data rows written