PDA

View Full Version : [SLEEPER:] merge files in folders



xitman
07-03-2024, 08:34 PM
Hi everyone,
First, I am very new to VBA, and I hope anyone here can help me solve this problem. I have a bundle of files, but in this session, I try to give or explain the simple way about my situation.


I have two folders. Each folder consists of 3 pdf files and needs to combine according to their filename.


Folder A
Location: C:\Users\Steve\Desktop
File: A_246, B_246, C_246


Folder B
Location: C:\Users\Steve\Desktop
File: A_246, B_246, C_246


Expected output in Folder C.


So, is it possible to combine the files in Folders A and B according to their names?


If yes, could any experts share the VBA code for this situation?
Thank you.

Aussiebear
07-03-2024, 11:05 PM
Rather than VBA, use Power Query to combine your files

jdelano
07-04-2024, 02:54 AM
You're looking to combine the PDF files, so folder C has one of A_246, B_246, C_246, and not read their contents into Excel?