VBA & Macro Problems

Fix Excel Workbook Reference Error When Opening VBA Add-Ins

Emma BrownEmma Brown Oct 23, 2026 869 views

Question details

The user wants to resolve an error preventing a workbook from closing because it is being referenced by another workbook via shared VBA procedures.

Fix Excel Workbook Reference Error When Opening VBA Add-Ins
Product
Microsoft Excel
Device & OS
not provided
Scenario
Opening and managing multiple VBA add-ins that reference shared procedures.
Observed behavior
Excel displays a warning message that a workbook is referenced by another workbook and cannot be closed.
Before you start

Before troubleshooting, ensure all unsaved work in your current Excel workbooks is saved, and temporarily disable any non-essential Excel add-ins to isolate the issue.

Solution 1Recommended

Report the Known VBA Issue to Microsoft Support

Since this is often a known issue with shared procedures in Excel VBA add-ins, submitting detailed feedback is the recommended Microsoft route.

This specific workbook reference locking is frequently tied to how Microsoft Excel handles memory allocation for multiple VBA add-ins sharing procedures. Reporting it directly helps prioritize a developer patch.

1
Open Excel Feedback

Open Microsoft Excel, navigate to the 'File' tab in the top-left corner, and select 'Feedback' from the left-hand menu.

2
Submit the Issue

Click on 'I Do Not Like Something' to open the feedback form. Detail the issue, specifically mentioning that multiple VBA add-ins referencing shared procedures cause the workbook reference error.

3
Seek Advanced Community Help

For immediate code-level workarounds, visit the Microsoft Q&A community and post your VBA structure specifics under the 'Office Excel IT Pro' or 'Office VBA Development' sections.

Report the Known VBA Issue to Microsoft Support
Community Troubleshooting: When posting in Microsoft Q&A, include the exact add-in cross-references and VBA module structures to get the most accurate assistance.
Free Microsoft Office alternative

Try WPS Office for Seamless Spreadsheet and Macro Management

If you frequently encounter complex VBA reference errors or bugs in Excel, consider switching to WPS Office. WPS Spreadsheet provides a stable environment for your data management needs without the heavy resource footprint.

  1. 1. Download and Install WPS Office: Visit the official WPS website to download and install the free, lightweight WPS Office suite.
  2. 2. Open Your Spreadsheet: Launch WPS Spreadsheet and open your existing .xlsx or .xlsm files seamlessly.
  3. 3. Manage Add-ins and Macros: Enable your macros in the WPS Spreadsheet environment to manage your automated tasks without encountering complex Excel-specific locking errors.
Highly compatible with Microsoft Excel (.xlsx) and macro-enabled (.xlsm) formats.Provides a stable environment that avoids many specific Microsoft Office VBA reference glitches.Free to use, lightweight, and features a familiar UI for a seamless transition.
microsoft office alternative - wps office

Frequently Asked Questions

Why does Excel say a workbook cannot be closed because it is referenced?

This typically happens when you have multiple VBA add-ins loaded that cross-reference each other's procedures. Excel locks the referenced workbook in memory to prevent code execution failure, stopping it from closing until the referring add-in releases it.

How do I safely remove a VBA add-in causing reference errors?

Go to File > Options > Add-ins. At the bottom of the window, select 'Excel Add-ins' from the Manage dropdown and click Go. Uncheck the suspected add-in, click OK, and restart Excel to fully clear the memory reference.

Can I use VBA macros in WPS Office?

Yes, WPS Office supports VBA macros. You can open your macro-enabled workbooks (.xlsm) and run your existing VBA scripts directly in the WPS Spreadsheet environment.