Add Data Row in a For Each Row Activity

I have a For Each Row Activity, in that activity i have a datatable as an input. The datatable contains a column and in every row there is a specific name.

I then do a specific action using each of the names for every row.
For each name I download a new excel file. I then use a Read Range activity and filter the Excel file with the “Filter Data Table” activity. Based on two columns and the rows that they contain i make a calculation. The result of the calculation I want to add to a new datatable along with the name.

I cant figure out how to add a row and build a new table within a “For Each Row” Activity.

I’m already using REF and the “Get Transcation Data” part to loop through other information in a datatable(excelfile).

Is it possible to add new data rows in a For each activity and then pass the information to a new datatable?

I feel like it gets overwritten if a have it inside a For Each row Activity. Would be better if it worked like the “Get Transaction Data” in the “REF main”.

Do you always want to add the information into the same ‘other’ datatable? if so then create the datatable using a build datatable activity or something similar, before you start looping through your For Each Row, then add the rows as you probably already have been. this way you wont create a new blank table over your last one on each iteration

1 Like

I got it to work, thank you so much.

I created the datatable in the INIT phase.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.