Fix Cannot Register MSBCODE964.OCX ActiveX Control in Excel
Question details
The user is unable to register or use the MSBCODE964.OCX ActiveX control, which is typically used for generating QR codes in Excel workbooks.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- Attempting to open a macro-enabled workbook or register a legacy QR code ActiveX control after a recent Microsoft 365 or Office 2024 update.
- Observed behavior
- The MSBCODE964.OCX control fails to register or load because ActiveX controls have been disabled by default in newer Office versions for security reasons.
Verify your current Microsoft Office version, as recent security updates to Microsoft 365 and Office 2024 automatically disable legacy ActiveX controls by default.
Replace Legacy OCX with Modern QR Code Solutions
Since ActiveX controls are disabled by default due to severe security risks, transitioning to a supported, modern QR-code generation method is the most reliable long-term fix.
Microsoft 365 and Office 2024 have deprecated default support for ActiveX controls like MSBCODE964.OCX to protect users from malicious code execution. Bypassing these security blocks globally is highly discouraged.
Instead of forcing the old control to register via the Windows registry, you should update your workbook to use modern, secure alternatives that do not rely on local OCX registrations.
Replace the ActiveX control with an Excel WEBSERVICE function or Power Query that calls a free, reliable QR code API to generate and display the code as an image directly in the cell.
Go to the 'Insert' tab on the Excel ribbon, click 'Get Add-ins', and search for 'QR Code' in the Office Store to install a maintained, officially supported generator.
If you are on Microsoft 365, navigate to the 'Automate' tab and write a modern Office Script (TypeScript) to handle the QR code generation securely within the cloud environment.

Temporarily Modify Trust Center Settings
If you absolutely must access legacy data tied to the MSBCODE964.OCX control for migration purposes, you can temporarily adjust Excel's Trust Center settings.
Generate QR Codes and Manage Macros Securely with WPS Office
Avoid the hassle of broken ActiveX controls and legacy VBA errors. WPS Office provides a lightweight, highly compatible, and secure environment for your spreadsheet needs, handling complex macros and modern integrations without legacy vulnerabilities.
- 1. Download WPS Office: Visit the official WPS website and download the free installation package for your operating system.
- 2. Install the Software: Run the installer and follow the simple on-screen instructions to set up WPS Office on your device.
- 3. Open Your Workbook: Launch WPS Spreadsheet and open your existing Excel file to continue working smoothly without legacy ActiveX errors.

Frequently Asked Questions
Why did MSBCODE964.OCX suddenly stop working in Excel?
Microsoft updated Microsoft 365 and Office 2024 to disable ActiveX controls by default due to significant security risks. This new security policy blocks legacy controls like MSBCODE964.OCX from running or registering automatically.
What exactly is MSBCODE964.OCX used for?
It is an older, third-party ActiveX control file typically used by developers to generate and embed QR codes or barcodes directly inside Excel worksheets using VBA.
Can I force register an OCX file in Windows 11?
Yes, you can use the 'regsvr32' command in an elevated Command Prompt. However, even if Windows registers it successfully, Excel's internal security policies in Microsoft 365 may still block the control from executing.
Is it safe to enable all ActiveX controls in Excel Trust Center?
No. Microsoft strongly advises against globally enabling ActiveX controls. Doing so disables crucial security protections and can allow malicious scripts to run automatically when you open an infected document from the internet.




