Insert New column in data sheet and copy data from another column

I am trying to insert new column and copying data from another column to the new column. But i am not able to get the output.Any suggestion or sample what i am missing ?

image

Hi @vignesh.maruthappan ,

Please refer to the attached Sample Sequence.
ForumQuestion.zip (10.2 KB)

Hope this helps you out.

Cheers.!

Thanks,
Gautham.

Hi @vignesh.maruthappan ,
->Use the “Read Range workbook” activity to read the data from your Excel file into a DataTable variable.

->Use the “Add Data Column” activity to add a new column to dtInput. Specify the name and data type of the new column

->Use a “For Each Row” activity to iterate through each row of dtInput.
Inside the “For Each Row” loop, use an Assign activity to copy data from an existing column to the new column.

row(“NewColumn”) = row(“ExistingColumn”).ToString

->After the loop, use the “Write Range” activity to write the updated DataTable (dtInput) back to the Excel file.

image

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