How do you properly append a data column as the end of your last row on an excel sheet? I’m trying to add a column of rows to state if an update has been completed.
How do you properly append a data column as the end of your last row? I'm trying to add a column of rows to state if an update has been completed
Just to answer this quickly,
The easiest way would be to use Read Range range inside an Excel Scope, and store your table into a DataTable,
Then, use Add Column activity if the column does not exist.
Then, to process each line item and update the status as you go use a
For each row In DataTable
Assign row(“Status”)=“Status Update”
The Assign will update the DataTable column for Status.
Lastly, you use Write Range to output your updated DataTable back to the file (you can also do this inside the ForEach loop if you want each line to be updated during the process)
There are alternate methods too, for when the Read Range or Write Range is failing cause it has too much data. For example, you can find the row you are processing (in various ways) and use Write Cell using a row number.