How to store strings inside a DataTable?

I am scraping 3 strings and storing them inside 3 variables. Now I need to store these 3 strings inside a Data Table in order to store them inside a CSV file. Can anyone guide me on achieving this task?

Create a new data table using build data table activity and then add row in it .


Try with Build DataTable and Add Data Row activity.


  1. Use build data table activity to create a datatable object.
    If you want to add the three variables values into three separate rows, then you will have one column specified in your build datatable. If you need to insert all the three values in one row, then create 3 columns in build data table.
  2. Use Add data row activity to add a row in the datatable.
    In the DataTable Property, mention the data table you built in step (1)
    In ArrayRow property mention the row values as {variable1Value, variable2Value, Variable3 value} for adding all the values in one row.

Hope this is helpful!


Hi @Madhavi,

Is it possible to iterate through the total number of colums of a csv file and write directly the string variables or do I need to create a datatable before writing to a csv file?

You need to build a datatable before writing into file