VBA & Macro Problems

Fix an Excel Macro Button That Only Works When a Ghost Button Is Clicked

Emma BrownEmma Brown Nov 14, 2026 869 views

Question details

The user needs an Excel macro button to respond when the visible button is clicked rather than at an offset location.

Fix an Excel Macro Button That Only Works When a Ghost Button Is Clicked
Product
Microsoft Excel
Device & OS
not provided
Scenario
A workbook with command buttons is used across a laptop display and an external monitor, potentially through a docking station.
Observed behavior
A button appears offset or duplicated, and the macro runs only when a ghost button or another location is clicked.
Before you start

Note which display shows the problem and whether the laptop is connected to a dock. Check whether the affected button is an ActiveX or Forms control before attempting to replace it.

Solution 1Recommended

Test the Workbook on the Laptop Display

Use this workaround to check whether the external display or dock is causing the button misalignment.

1
Move Excel to the laptop

Drag the Excel window onto the primary laptop display, then click the visible macro button to test it.

2
Disconnect the external setup

If the button is still offset, disconnect the external monitor or undock the laptop, then test the button again.

3
Compare display scaling

Open your device's display settings and compare the scaling settings for the laptop and external monitor. If possible, use consistent scaling, then reopen the workbook and test the button on each screen.

Test the Workbook on the Laptop Display
If the issue returns: If the button works on the laptop but becomes offset after reconnecting the dock or moving Excel to the external monitor, keep the workbook on the laptop display as a workaround.
Free Microsoft Office alternative

Work with Spreadsheets in WPS Office

WPS Office is a free, lightweight Office alternative with a familiar interface and support for Microsoft Excel formats, making it easier to move everyday spreadsheet work. Test macro-enabled workbooks and controls before relying on them, as compatibility can differ from Excel.

Open and edit spreadsheets in a familiar interfaceCompatible with Microsoft Excel formats such as XLSX and XLSMReview workbook layouts and buttons when evaluating an Office alternativeFree and lightweight for everyday office tasks
microsoft office alternative - wps office

Frequently Asked Questions

Why does my Excel button respond in the wrong location?

Different display scaling settings or a docking setup can cause controls to appear misaligned. Move Excel to the laptop display and test the button, then compare scaling in your device's display settings.

How can I tell if the button is an ActiveX control?

On Excel's Developer tab, turn on Design Mode and right-click the button. If the menu includes Properties, the button is an ActiveX control.

Can I assign ActiveX click code directly to a Forms button?

Not necessarily. A Forms button needs a callable macro; ActiveX click-event code may need to be moved or adapted to a public procedure in a standard VBA module. Then select the procedure in the button's Assign Macro dialog.

What should I do if the button works only after undocking?

Test the workbook on the laptop display without the dock. If the issue returns when you reconnect it, use the laptop display as a workaround and compare the scaling settings of the connected displays.