Hi, I have a strange problem that I can’t find a solution for. I am reading from an Excel sheet and using a “For each” activity entering a value into a website for data scraping. The results are read into a data table. All very standard and working fine.
Then the robot is reading the scraping output datatable and enter the values into an Excel sheet. Then the robot run a VBA code to filter the values. (Too complex for the filter table activity). Everything good so far. Then the result after running the VBA code is read using a “Read range” activity, and written into a different sheet using the Append range activity. All very standard, but this is where something goes wrong.
When the robot appends the values, every time the robot do a “For each loop” it writes in the new value, but also keep the past values. What can cause this?
Please have a look at the attached screenshot that show an example outcome of the append activitiy. The values with green background should be there, the red ones should not.
Yes, I am aware of that, and I am clearing it. That is the strange thing. So I was thinking the problem is in Excel, not UIPath. I have also tried “Write range” and a counter. Same thing
Instead of append range activity use write range activity as append range will keep the already existing records in the excel while write range will over write it
And also use CLEAR DATATABLE Activity before inserting new value to that datatable