How could you merge excel files? I am talking about approximately more than 100 excel files that must be joined or merged into a single file, and later uploaded to google sheet.
Excel files have the same format of fields, columns, etc.
Welcome to the community
- Use for each file in folder activity with filter on
- Inside the loop use read ramge workbook and read the data into datatable
- Use if condition to check if this is the first iteration
- On then side use
finaldt = dt.Clone and then
finaldt = dt.CopyDataTable
- Else side use merge datatable and merge dt with finaldt
- Outside loop use write range and write the finaldt to new excel
Hope the following sample helps you.
Sample20230531-3.zip (15.3 KB)