How to Fix MSCOMCTL32.OCX TreeView Errors in 64-Bit Office VBA
Question details
The user needs to fix errors that occur when inserting or using the MSCOMCTL32.OCX TreeView control in a VBA UserForm.

- Product
- Microsoft Office VBA
- Device & OS
- not provided
- Scenario
- Attempting to use legacy Visual Basic 6 TreeView controls within VBA UserForms in a 64-bit Office environment, particularly in newer PowerPoint builds.
- Observed behavior
- The TreeView control fails to load or triggers a compatibility error because MSCOMCTL32.OCX is a 32-bit legacy control that cannot run natively in 64-bit Office.
Verify whether your installation of Microsoft Office is 32-bit or 64-bit, as this architectural difference is the primary cause of the control failure.
Install the 32-Bit Version of Microsoft Office
The most reliable way to use legacy 32-bit VB6 controls like MSCOMCTL32.OCX is to run the 32-bit version of Office.
MSCOMCTL32.OCX is a legacy 32-bit Visual Basic 6 control. Because 64-bit applications cannot load 32-bit components directly into their memory space, this control will natively fail in 64-bit Office environments. Switching to the 32-bit version of Office restores full compatibility.
Open any Office application like PowerPoint or Excel. Navigate to File > Account > About PowerPoint. Look at the top line to see if it says 64-bit or 32-bit.
If you are running the 64-bit version, close all Office apps. Open the Windows Control Panel, go to Programs and Features, select Microsoft Office, and click Uninstall.
Log into your Microsoft account online, download the Office installer, select 'Other install options', and explicitly choose the 32-bit version from the dropdown menu before installing.

Replace TreeView with a 64-Bit Compatible Alternative
If you must remain on 64-bit Office, you will need to replace the legacy TreeView control with a modern or alternative method.
Experience Seamless VBA Compatibility with WPS Office
Struggling with VBA architecture errors and legacy controls in Microsoft Office? WPS Office provides a lightweight, highly compatible alternative with excellent support for VBA macros and familiar interfaces, ensuring you can continue your work without complex workarounds.
- 1. Download and Install: Download WPS Office Free from the official website and follow the lightweight installation process.
- 2. Open Macro-Enabled Files: Launch WPS Office and open your existing .xlsm, .pptm, or .docm files directly.
- 3. Access the VBA Editor: Navigate to the Developer tab on the ribbon and click on the VBA Editor to view and manage your macros.

Frequently Asked Questions
Why does MSCOMCTL32.OCX work in VB6 but not in Office 64-bit?
Visual Basic 6 is inherently a 32-bit environment, which seamlessly supports the 32-bit MSCOMCTL32.OCX file. Office 64-bit runs in a 64-bit memory space and cannot natively load 32-bit ActiveX controls, causing it to throw errors when attempting to render them.
Can I register MSCOMCTL32.OCX on a 64-bit Windows system?
Yes, you can register it on 64-bit Windows using the 32-bit version of regsvr32 (located in C:\Windows\SysWOW64). However, doing this only makes the control available for 32-bit applications (like 32-bit Office), not 64-bit applications.
Is there an official 64-bit version of MSCOMCTL32.OCX available?
No, Microsoft has never released a 64-bit version of the Windows Common Controls (MSCOMCTL32.OCX). If you require 64-bit compatibility, you must use native VBA controls or find a third-party 64-bit component.




