How to list all open workbooks and easily shift between workbooks in Excel?
Microsoft Excel allows you to open multiple workbooks at the same time, but it’s not easy for you to shift between all open workbooks. So you may want to list all open workbooks in a list for easily shifting between those workbooks in Excel. In this article, we will show you how to list all open workbooks for easily navigation in Excel.
Just list all open workbooks with VBA
List all open workbooks and shift to a workbook easily with VBA
List all open workbooks and easily shift to a workbook with an amazing tool
| Feature | VBA: List Workbooks and Worksheets | VBA: List and Switch Workbooks | Kutools Navigation Pane |
|---|---|---|---|
| Main purpose | Lists the names of all open workbooks and their worksheets in worksheet cells | Displays open workbook names in a dialog box and activates a specified workbook | Automatically displays all open workbooks in a navigation pane |
| Lists open workbooks | Yes | Yes | Yes |
| Lists worksheet names | Yes | No | Yes |
| Switches directly to a workbook | No | Yes, by entering the workbook name | Yes, with one click |
| Updates automatically | No, the code must be run again | No, the code must be run again | Yes |
| Requires VBA knowledge | Yes | Yes | No |
| Requires manual input | Users must select an output cell | Users must type the exact workbook name | No manual input is required |
| Number of steps | Multiple steps | Multiple steps | One-click navigation |
| Ease of use | Moderate to difficult | Moderate to difficult | Simple and convenient |
| Best suited for | Creating a static workbook and worksheet reference list | Users who occasionally need to activate a workbook through VBA | Frequently working with and switching between multiple workbooks |
Just list all open workbooks with VBA
In this section, you will learn how to use a VBA code for listing all open workbooks in Excel.
1. Press Alt + F11 keys to open the Microsoft Visual Basic for Applications window. In the Microsoft Visual Basic for Applications window, click Insert > Module.

2. Then copy and paste the below VBA code into the code editor.
VBA: list all open workbook names in Excel
Sub ListWorkbooks()
Dim Rng As Range
Dim WorkRng As Range
On Error Resume Next
xTitleId = "KutoolsforExcel"
Set WorkRng = Application.Selection
Set WorkRng = Application.InputBox("Out put to (single cell)", xTitleId, WorkRng.Address, Type: = 8)
Set WorkRng = WorkRng.Range("A1")
xNum1 = Application.Workbooks.Count
For i = 1 To xNum1
xNum2 = Application.Workbooks(i).Sheets.Count
WorkRng.Offset(i - 1, 0).Value = Application.Workbooks(i).Name
For j = 1 To xNum2
WorkRng.Offset(i - 1, j).Value = Application.Workbooks(i).Sheets(j).Name
Next
Next
End Sub 3. Run the VBA code by pressing the F5 key. In the KutoolsforExcel dialog box, specify a cell for placing the workbook list, and then click the OK button. See screenshot:

Then all open workbooks with corresponding worksheets are listed out.
Hard to handle VBA code? You can acheive it through thethird method with clicks.
List all open workbooks and shift to a workbook easily with VBA
If you want to list all workbooks for easily shift between workbooks, please try to use the VBA as follows:
1. Press the Alt + F11 to open the Microsoft Visual Basic for Applications window. In the Microsoft Visual Basic for Applications window, click Insert > Module.

2. Copy and paste the following VBA code into the open module window.
VBA code: list all open workbooks and shift to a workbook
Sub SelectWB()
Dim xWBName As String
Dim xWb As Workbook
Dim xSelect As String
For Each xWb In Application.Workbooks
xWBName = xWBName & xWb.Name & vbCrLf
Next
xTitleId = "KutoolsforExcel"
xSelect = Application.InputBox("Enter one of the workbooks below:" & vbCrLf & xWBName, xTitleId, "", Type: = 2)
Application.Workbooks(xSelect).Activate
End Sub 3. Press the F5 key to run the code. Then a KutoolsforExcel dialog box pops up with a list of all open workbooks. If you want to shift to a specified workbook, please enter this workbook name into the box and click the OK button. See screenshot:

List all open workbooks and easily shift to a workbook with an amazing tool
With the Navigation pane of Kutools for Excel, all open workbooks will be listed automatically inside a pane for you to easily navigate between all open workbooks. You just need to click on one of the open workbooks and it will navigate to that workbook immediately.

Conclusion
The first VBA method is useful when you need to create a static list of all open workbooks and their worksheets. However, it does not provide a direct way to switch between the listed workbooks.
The second VBA method allows you to activate an open workbook, but you must run the macro and manually enter the exact workbook name each time. Both VBA methods also require users to work with the Visual Basic Editor and may need to be rerun whenever the list of open workbooks changes.
For users who frequently manage multiple workbooks, the Kutools for Excel Navigation Pane is the most convenient option. It automatically displays open workbooks and worksheets in a persistent pane and allows users to switch to any workbook with a single click, without writing or running VBA code.
Best Office Productivity Tools
Supercharge Your Excel Skills with Kutools for Excel, and Experience Efficiency Like Never Before. Kutools for Excel Offers Over 300 Advanced Features to Boost Productivity and Save Time. Click Here to Get The Feature You Need The Most...
Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier
- Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
- Open and create multiple documents in new tabs of the same window, rather than in new windows.
- Increases your productivity by 50%, and reduces hundreds of mouse clicks for you every day!
All Kutools add-ins. One installer
Kutools for Office suite bundles add-ins for Excel, Word, Outlook & PowerPoint plus Office Tab Pro, which is ideal for teams working across Office apps.
- All-in-one suite — Excel, Word, Outlook & PowerPoint add-ins + Office Tab Pro
- One installer, one license — set up in minutes (MSI-ready)
- Works better together — streamlined productivity across Office apps
- 30-day full-featured trial — no registration, no credit card
- Best value — save vs buying individual add-in