VBA & Macro Problems

How to Fix Excel VBA Code Window Stuck or Cannot Move on Mac

Bushra ParveenBushra Parveen Nov 3, 2026 868 views

Question details

The Excel VBA editor window becomes maximized or stuck on macOS, making it impossible to minimize or move.

How to Fix Excel VBA Code Window Stuck or Cannot Move on Mac
Product
Microsoft Excel for Mac
Device & OS
macOS
Scenario
Editing VBA macros when multiple code windows are open and one gets maximized.
Observed behavior
The VBA code window gets stuck in a maximized state, cannot be moved vertically, and other windows also maximize without the ability to restore them.
Before you start

Before troubleshooting, ensure you have saved your macro code in a separate text file as a backup and verify that your Mac has the latest system updates installed.

Solution 1Recommended

Transfer Code to a New Module or Workbook

Move your existing VBA code to a fresh module or an entirely new workbook to reset the window behavior.

This glitch often happens in older versions of Excel on Mac (like version 16.44 on Big Sur) when one of the code windows is maximized, causing all subsequent windows to lock in a maximized state. Recreating the module forces the VBA editor to reset the layout properties.

1
Copy the existing code

Open the stuck VBA editor window in Excel for Mac, select all of your macro code, and copy it to your clipboard.

2
Insert a new module

In the Project Explorer pane on the left side of the Visual Basic Editor, right-click your VBAProject, select 'Insert', and choose 'Module'.

3
Paste and save

Paste your copied code into the newly created module window.

4
Delete the stuck window

Right-click the old, problematic module in the Project Explorer, select 'Remove', and choose 'No' when asked if you want to export it before removing.

Transfer Code to a New Module or Workbook
Workbook Transfer: If recreating the module doesn't work, pasting the code into a completely new Excel workbook will typically bypass any corrupted project folder settings.
Free Microsoft Office alternative

Try WPS Office for a Stable Spreadsheet Experience

If you frequently encounter interface bugs or stuck windows in Microsoft Excel for Mac, consider switching to WPS Office. It provides a highly compatible, lightweight, and smooth spreadsheet editor without the hassle of recurring display glitches.

  1. 1. Download the software: Visit the official WPS Office website and download the installation package designed for macOS.
  2. 2. Install WPS Office: Open the downloaded file and follow the on-screen instructions to drag and drop WPS Office into your Applications folder.
  3. 3. Open your macro workbook: Launch WPS Spreadsheets and open your existing .xlsm or .xlsx files to continue your work without experiencing stuck windows.
Fully compatible with Microsoft Excel formats (.xlsx, .xls) and macro-enabled files.Lightweight design ensuring smooth performance on macOS without UI freezing.Clean, intuitive interface similar to Microsoft Office for a seamless transition.Free to download and use for your daily spreadsheet and document tasks.
microsoft office alternative - wps office

Frequently Asked Questions

Why do all my VBA windows maximize when I maximize one on Mac?

This is a known interface glitch in certain versions of Excel for Mac (such as version 16.44). Once one window is maximized, the application struggles to restore the cascading or tiled window views, forcing all other windows to follow suit.

Can I reset the VBA window layout without deleting my code?

Sometimes using the 'Window' menu options in the VBA editor to tile or cascade windows can temporarily reset the layout. However, if the window is deeply stuck, copying the code to a new module is the most reliable fix.

Does WPS Office support Excel macros?

Yes, WPS Office provides excellent support for VBA macros in its professional and certain regional editions, allowing you to run and edit your existing Excel macros seamlessly.

Where are VBA modules saved in Excel for Mac?

VBA modules are stored within the workbook file itself. You can view, export, or delete them using the Project Explorer pane inside the Visual Basic Editor.