• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Macro to copy multiple workbooks to a master workbook

Jlav

New Member
I am not an expert with macros. Here is my situation: I have 20 Excel 2007 Workbooks (All are the same) just different users. Each file is saved with the users first and last name. I need to create a macro in my master workbook that can copy each worksheet from each workbook to my master selected master worksheetsheet. All files reside in the same folder. I have users using excel 2007 and excel 2010. The macros needs to work for both Excel versions. Any suggestions?


Thanks!!
 
Hi, Jlav!


First of all welcome to Chandoo's website Excel forums. Thank you for your joining us and glad to have you here.


As a starting point I'd recommend you to read the three first green sticky topics at this forums main page. There you'll find general guidelines about how this site and community operates (introducing yourself, posting files, netiquette rules, and so on).


Among them you're prompted to perform searches within this site before posting, because maybe your question had been answered yet.


Feel free to play with different keywords so as to be led thru a wide variety of articles and posts, and if you don't find anything that solves your problem or guides you towards a solution, you'll always be welcome back here. Tell us what you've done, consider uploading a sample file as recommended, and somebody surely will read your post and help you.


And about your question...


Please clarify this points:

a) how many worksheets has each workbook?

b) if more than one, are there specific worksheet names to process?

c) in your master workbook, should all the individual worksheets of each workbook be copied to the same worksheet or just should the information be aggregated by worksheet name?


Regards!
 
Thanks SirJB7 for the quick response. I will read and review the three first green sticky topics.


Clarification:

a) how many worksheets has each workbook? 4

b) if more than one, are there specific worksheet names to process? One specific worksheet name with a set range

c) in your master workbook, should all the individual worksheets of each workbook be copied to the same worksheet or just should the information be aggregated by worksheet name? The individual worksheet (Specific name with a set range) should be copied to the master (also a specific worksheet name and ranges)


Thanks!
 
Hi, Jlav!


Give a look at this file:

https://dl.dropbox.com/u/60558749/Macro%20to%20copy%20multiple%20workbooks%20to%20a%20master%20workbook%20%28for%20Jlav%20at%20chandoo.org%29.zip


Just advise if any issue.


Regards!


PS: each new worksheet in master file is named as original source workbook and if longer than 31 characters renamed as date&time&counter.
 
Jlav,

If SirJB7's solution does not work, you should also check out Ron's Copy/Paste/Merge examples here:

http://www.rondebruin.nl/tips.htm


He gives several ways to merge workbooks into a single file.
 
Back
Top