VBA & Macro Problems

Fix an Excel ActiveX Button That Does Not Run VBA Code

Chanuka GeekiyanageChanuka Geekiyanage Nov 14, 2026 870 views

Question details

An Excel ActiveX button does not respond to clicks even though its VBA code runs from the editor.

Fix an Excel ActiveX Button That Does Not Run VBA Code
Product
Microsoft Excel
Device & OS
Windows (Surface reported)
Scenario
The workbook is moved between monitors that use different display scaling settings.
Observed behavior
Clicking the ActiveX command button does not trigger its VBA code, while running the code from the VBA editor works.
Before you start

Connect the monitors you normally use and check the scaling percentage for each one in Windows Display settings. Open the workbook in Excel and confirm that the button is an ActiveX control.

Solution 1Recommended

Match the Display Scaling on All Monitors

Use this fix when the button stops responding after the workbook is moved between displays with different scaling settings.

1
Open Display settings

Right-click the Windows desktop and select Display settings.

2
Check each monitor

Select each display in the diagram and look at Scale under Scale & layout.

3
Match the scaling

Choose the same Scale percentage for each connected monitor. In the reported case, changing the third monitor from 150% to 125% resolved the issue.

4
Test the button

Return to Excel and click the ActiveX button. If needed, close and reopen Excel before testing again.

Match the Display Scaling on All Monitors
Scaling options may vary: Choose a scaling percentage available on all your monitors; the percentage that worked in the reported case may not suit every setup.
Free Microsoft Office alternative

Work with Spreadsheets in WPS Office

WPS Office is a free, lightweight alternative with a familiar interface for opening and editing Office documents. It can help you move everyday spreadsheet work to WPS, but it does not fix Excel's ActiveX issue, and ActiveX controls or VBA macros may not work the same way.

Open and edit Microsoft Excel XLSX filesUse familiar spreadsheet tools for everyday workbook tasksWork in a lightweight, easy-to-use Office alternativeMove common Office documents between Microsoft Office and WPS Office
microsoft office alternative - wps office

Frequently Asked Questions

Why does the VBA code run in the editor but not when I click the button?

The code itself may run while the button fails to receive the click. Different monitor scaling settings were the cause in the reported case; Design Mode or security restrictions can also prevent normal use.

Where can I check each monitor's scaling?

Right-click the Windows desktop, select Display settings, and select each monitor in the display diagram. Check Scale under Scale & layout.

How do I know if Excel is in Design Mode?

Open the Developer tab and look at the Design Mode button. Turn it off before testing an ActiveX button.

Can WPS Office fix an Excel ActiveX button?

No. The display-scaling and ActiveX problem must be addressed in Windows or Excel. WPS Office can open and edit many Excel files, but ActiveX controls and VBA macros may not behave the same way.