Description
Appends a DataTable to the CSV.
Attributes
Input
DataTable - The DataTable to be written unto the selected CSV file.
Options
AddHeaders - True or False value to add headers on the CSV file.
Encoding - The type of encoding for the CSV.
Common
ContinueOnError - The Boolean value to specify whether to continue executing the next activities even if there is an error thrown on this activity.
Misc
DisplayName - Renames the activity.
Example
- Create a DataTable variable and name it dt.
- Add a Generate Data Table inside the initial Sequence.
- In the Generate Data Table Date Table field under Attributes, add the dt variable.
- In the Generate Data Table ColumnSeparators field under Attributes, write ";"
- In the Generate Data Table NewLineSeparator fieldunder Attributes, write "|".
- In the Generate Data Table Input field, type "M; 23|F; 24|F; 25". This would be the sample values inside the data table.
- Under the Generate Data Table, add a CSV Sequence.
- In the CSV Sequence File Path field, search and select the CSV document that will use.
- In the CSV Sequence Delimiter field, write ','.
- Inside the CSV Sequence, add a CSV Write activity.
- In the CSV Write DataTable field, add the dt variable.
The use case should look as the following screenshot:
After the execution, the generated data table should be appended into the specified CSV document.