Using Excel for office work often requires copying sheets from one workbook to another. You might need to compile individual employee sales reports into a single workbook.
Or, you might need to compile your weekly reports into a workbook of monthly reports. In other circumstances, your boss might want to see some specific Excel Sheets of yours from multiple workbooks.
Whatever the purpose, copying individual sheets from one workbook to another is quite a simple process.
But what if you want to copy multiple sheets to a new workbook? An efficient Excel user would always want to speed things up and automate as much of the process as possible.
So here are a few ways to help you quickly copy multiple sheets in Excel to a new workbook.
How to Manually Copy Multiple Sheets to Another Workbook
One way to copy multiple sheets to another workbook is to do it manually.
While this may take you a couple more clicks and a few more seconds, if you only need to do this once in a while, doing it manually is the way to go.
Now there can be two scenarios when you’re copying sheets:
- Copy all the sheets (or selected sheets) to an already open workbook
- Copy selected sheets to a new workbook
Copy sheets to an already open workbook
Let’s first look at how to manually copy all sheets or multiple sheets to an already open Excel workbook:
- Open the workbook that has the worksheets that you want to copy (as well as the one where you want these to be copied)
- Hold down the CTRL key of your keyboard and select the tabs of the sheets that you want to copy.
- Keeping your cursor on any one of these selected sheet tabs, right-click with your mouse
- Select “Move or Copy” from the popup menu that appears. This will open the “Move or Copy” dialog box.
- In the ‘Move or Copy’ dialog box, click on the ‘To book:’ drop-down and select the workbook name to which you want to copy the selected sheets
- Check the ‘Create a Copy’ option (if not checked, your sheets will be removed from the current workbook and moved to the new one).
- Click OK.
The above steps would move a copy of all the selected sheets to the selected workbook.
Copy selected sheets to a new workbook
Now let’s see how to copy and move some of the sheets in the current workbook into a new workbook.
Below are the steps to do this:
- Open the workbook that has the worksheets that you want to copy
- Hold down the CTRL key of your keyboard and select the tabs of the sheets that you want to copy.
- Keeping your cursor on any one of these selected sheet tabs, right-click with your mouse
- Select “Move or Copy” from the popup menu that appears. This will open the “Move or Copy” dialog box.
- In the ‘Move or Copy’ dialog box, click on the ‘To book:’ drop-down and select ‘(new book)’ option
- Check the ‘Create a Copy’ option (if not checked, your sheets will be removed from the current workbook and moved to the new one).
- Click OK.
The above steps would automatically create a new workbook and copy the selected sheets into this new workbook. Note that these are copies and the original worksheet still remains in the original workbook (since we checked the ‘Create a Copy’ option).
Now you can save this new workbook that has the copied sheets.
Also read: How to Separate Excel Tabs Into Separate Files
Copy Sheets to Another Workbook (Using VBA)
Copying sheets manually is fine if you have to do it once in a while, but if you have to do it regularly, then automating this using VBA can be better.
In this section, I will cover some scenarios where you can use VBA to copy sheets from one workbook into another.
Copy Sheets with Specific Names Into Another Workbook
If you always have this need to copy sheets with a specific name to a new workbook, you can easily do this with a simple VBA code.
The below code with copy and move the sheets with the name “Sales”, “Marketing” and “Operations” into a new workbook. Of course, you can change the names and add/remove more sheets to be a part of this code.
Sub CopySheets() Workbooks("Book1.xlsx").Sheets("Sales").Copy _ After:=Workbooks("Dbook.xlsx").Sheets(Workbooks("Dbook.xlsx").Sheets.Count) Workbooks("Book1.xlsx").Sheets("Marketing").Copy _ After:=Workbooks("Dbook.xlsx").Sheets(Workbooks("Dbook.xlsx").Sheets.Count) Workbooks("Book1.xlsx").Sheets("Operations").Copy _ After:=Workbooks("Dbook.xlsx").Sheets(Workbooks("Dbook.xlsx").Sheets.Count) End Sub
The above code simply copies the sheets with the specified name (Sales, Marketing, Operations in this example) and move the copy to the destination workbook (which is Dbook.xlsx)
In this case, you can run the VBA code in any of the workbooks.
Another good use-case of this code could be when you have multiple workbooks and you want to copy and bring specific worksheets into the destination workbook.
For example, suppose you have three workbooks – with the name WB1, WB2, and WB3, and you want to get the sheets from these workbooks into the destination workbook.
Instead of doing it one at a time for each workbook, you can tweak the above VBA code to get specific sheets from multiple workbooks into the destination workbook.
Below is the code that’s will copy and move a sheet (named “Summary”) from all the workbooks into the destination workbook (DBook.xlsx in this example).
Sub CopySheets() Workbooks("Sales.xlsx").Sheets("Summary").Copy _ After:=Workbooks("Dbook.xlsx").Sheets(Workbooks("Dbook.xlsx").Sheets.Count) Workbooks("Marketing.xlsx").Sheets("Summary").Copy _ After:=Workbooks("Dbook.xlsx").Sheets(Workbooks("Dbook.xlsx").Sheets.Count) Workbooks("Operations.xlsx").Sheets("Summary").Copy _ After:=Workbooks("Dbook.xlsx").Sheets(Workbooks("Dbook.xlsx").Sheets.Count) End Sub
This VBA code needs to be run in the DBook.xlsx workbook.
Copy Sheets with Specific Text Into Another Workbook
In some cases, you may have a workbook and you want to copy all the sheets that have a specific word in it.
For example, I may want to copy and move all the sheets that have the text 2020 in it to another workbook (let’s say DBook.xlsx).
The following VBA code can do this:
Sub CopySheets() Dim Sh As Worksheet For Each Sh In Worksheets If InStr(1, Sh.Name, "2020", vbBinaryCompare) > 0 Then Sh.Copy After:=Workbooks("Dbook.xlsx").Sheets(Workbooks("Dbook.xlsx").Sheets.Count) End If Next Sh End Sub
The above uses the INSTR function to find the position of the text 2020 in the sheet name. If it finds the text in the sheet name, then it copies that sheet, else it doesn’t.
So this code will make sure that only those sheets that have a specific text string in it are copied.
This can be really useful if you have a huge workbook and you want to quickly segregate sheets based on the year or department or any other code which is mentioned in each sheet name.
This VBA code needs to be run in the sheet where you have the sheets that need to be copied. Also, note that you need to have the destination workbook open for this to work.
So these are some of the ways you can use to copy multiple sheets to a new workbook or any other open workbook. In most cases, doing it manually will serve the purpose, but in case you need to do this quite regularly, you can also automate this process using the simple VBA codes mentioned above.
I hope you found this Excel tutorial useful!
Other Excel tutorials you may like:
- How to Delete a Sheet in Excel Using VBA
- How to Print Multiple Sheets in Excel
- How to Unhide All Rows in Excel with VBA
- How to Move a Chart to a New Sheet in Excel
- How to Save Selection in Excel as PDF
- 3 Ways to Duplicate Sheet in Excel
- How to Merge Two Excel Files?
- How to Link Cells in Excel (Same Worksheet, Between Worksheets/Workbooks)
- Insert New Sheet in Excel (Shortcut)