How to copy data into a column in an excel without changing the data format of other columns

In HR database I have to enter the employee details which I will receive in input excel file. Once after successful entry of each employee details I have to update a column in same input excel file “status” with “Success” along with the “Employee ID” created.
When I am doing this using ‘for each row’ activity and ‘Assign’ activity to assign values to that Data row and copying to datatable by using ‘Assign’ activity again “datarowDR.copy to DataTable”
Result: Successfully status and employee ID column updated but since we are copying whole datatable and pasting it back it is changing the other column’s format for example Reference number column we have number starting with zero
Reference Number = 03456 after copy datatable it is converting into Reference Number = 3456.
If I use ‘write cell’ activity it is talking much more time then copy to datatable and also it is unable to identify if the row index changes.
Kindly provide me a solution without effecting the data format
Thank you in advance!

It would be good if u use write cell I think

@sushmithakiran02

Nived N :robot:

If you are using Excel write cell then your format will disturb . Use write cell activity of workbook.

Or you can add 'ref. No like '03456 … Adding ’ will treat your no. As string

I have used write range activity of workbook it worked well. Thank you :grinning:

1 Like

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