After closing a workbook, it still shows in the VBA project list

Henrik Vestergaard 65 Omdømmepoint
2026-03-06T08:27:29.4366667+00:00

After closing a workbook, it still shows in the VBA project list.

When working with multiple Excel files this is a pain.

How to avoid or close the VBA projects, without closing Excel completely?

Microsoft 365 og Office | Excel | Andet | Windows
0 kommentarer Ingen kommentarer

Svar accepteret af spørgsmålets forfatter
Xavier-D 13,580 Omdømmepoint Eksternt Microsoft-personale Redaktør
2026-04-01T00:45:39.6733333+00:00

Disclaimer: Due to this thread is posted in Danish locale forum. But because you use English for this post, I will answer according to the language you use. If you need me to answer in Danish, please feel free to let me know, I'll answer in the language you are comfortable with.  


Hello Henrik Vestergaard

Thank you for the details. What you’re seeing appears to match a known behavior where a workbook’s VBA project can remain visible in the Visual Basic Editor (VBE) after the workbook itself has been closed.

A full restart of Excel is the most reliable way to clear the stale VBA project. If you would like to reduce how often this happens, please try these short checks:

  • Review COM add-ins
    Go to File > Options > Add-ins > Manage: COM Add-ins > Go. Temporarily disable nonessential add-ins and test again. Some users reported improvement after disabling certain add-ins such as Microsoft DataStreamer for Excel, and another report mentioned Google Drive as a possible factor. You can read about this info here: VBAProject remains in VBE after workbook is closed — persists in Safe Mode
  • Check for lingering VBA object references
    If the issue mainly happens with macro-enabled workbooks, unreleased object references can sometimes keep a project in memory. One workaround is to select the affected project in the VBE, open the Immediate Window, and run End to clear active VBA state.
  • Update or repair Office
    It may also help to install the latest Office updates and run an Office Repair, refer to this site for instruction: Repair an Office application

Feel free reply back to this post and update me on this issue, I'll be happy to help.

Var dette svar nyttigt?

1 person fandt dette svar nyttigt.

0 ekstra svar

Sortér efter: Ældste

Dit svar

Svar kan markeres som "Accepteret" af spørgsmålsforfatteren og "Anbefalet" af redaktører, hvilket hjælper brugerne med at vide, at svaret løste forfatterens problem.