You open a spreadsheet or Access database that worked fine for years, click a button, and get slapped with Run-time error '429': ActiveX component can't create object. The form that used to show a calendar picker is blank. The TreeView that displayed your inventory hierarchy is gone. Nothing has changed in your code, yet everything is broken.
This is one of the most common errors in legacy Microsoft Office files, and it has gotten significantly worse since Microsoft started blocking ActiveX controls by default in Office 365. This guide walks through every cause and every fix, from a simple DLL re-registration to a full control replacement strategy.
When VBA executes a line like Set obj = CreateObject("MSCAL.Calendar") or Dim tv As New MSComctlLib.TreeView, it asks Windows to locate and load a COM/ActiveX component. Error 429 fires when that lookup fails. Windows checked the registry, couldn't find a valid entry for the requested object, or found the entry but couldn't load the DLL/OCX file it pointed to.
The error message is frustratingly vague. It doesn't tell you which component failed or why. But the causes fall into four categories:
Let's fix each one.
This is the most common cause on machines that have been upgraded, reimaged, or moved to new hardware. The ActiveX control file exists somewhere on disk but isn't registered in the Windows registry, or the file was never copied over during migration.
Open the VBA editor (Alt+F11), go to Tools > References, and look for any reference marked MISSING. That's your culprit. Common offenders:
| Reference Name | File | Controls Provided |
|---|---|---|
| Microsoft Common Controls 6.0 | MSCOMCTL.OCX | TreeView, ListView, ImageList, StatusBar, Toolbar, ProgressBar |
| Microsoft Common Controls-2 6.0 | MSCOMCT2.OCX | DateTimePicker, MonthView, UpDown |
| Microsoft Calendar Control | MSCAL.OCX | Calendar date picker |
| Microsoft FlexGrid Control | MSFlxGrd.OCX | MSFlexGrid, MSHFlexGrid |
| Microsoft Windows Common Controls-3 | COMCT332.OCX | CoolBar, ImageCombo |
| Microsoft Rich Textbox Control | RICHTX32.OCX | RichTextBox |
Open an elevated Command Prompt (right-click > Run as administrator) and register the control:
:: For 32-bit controls on a 64-bit Windows machine:
regsvr32 C:\Windows\SysWOW64\mscomctl.ocx
regsvr32 C:\Windows\SysWOW64\mscomct2.ocx
regsvr32 C:\Windows\SysWOW64\msflxgrd.ocx
regsvr32 C:\Windows\SysWOW64\mscal.ocx
:: For 64-bit controls (rare — most legacy controls are 32-bit):
regsvr32 C:\Windows\System32\mscomctl.ocx
If the file doesn't exist in those folders, you'll need to copy it from a working machine or download the Visual Basic 6.0 Common Controls redistributable from Microsoft. The file must go in SysWOW64 for 32-bit controls on 64-bit Windows (counterintuitively, System32 is for 64-bit files).
You should see a message box saying "DllRegisterServer in [filename] succeeded." If you get an error instead, the file is either corrupt, the wrong bitness, or you don't have admin rights.
This is the silent killer of legacy Office files. Most ActiveX controls from the VB6 era are 32-bit only. If your organization upgraded to 64-bit Office (which has been the default installation since Office 2019), every one of those controls will throw Error 429.
There is no compatibility layer. A 32-bit OCX cannot load in a 64-bit process, period.
Open Excel or Access, go to File > Account > About. In the dialog that opens, the very first line will say either 32-bit or 64-bit.
You can also check programmatically in VBA:
#If Win64 Then
MsgBox "64-bit Office"
#Else
MsgBox "32-bit Office"
#End If
CreateObject("SomeApp.Object"), check whether a 64-bit version of that application is available.For most organizations with more than a handful of legacy files, option 2 is the right answer. Manual replacement is tedious but permanent.
LegacyLeaps maps 24 legacy ActiveX controls to modern replacements automatically. Upload your files, see exactly which controls need replacing, and get converted code.
Try the Free ScanIn October 2024, Microsoft rolled out a significant security change: ActiveX controls are now disabled by default in Microsoft 365 (Office 365) desktop applications. This affects Word, Excel, Access, PowerPoint, and Visio.
This means even if the OCX file is properly registered and the bitness matches, Office will refuse to load the control. You'll see Error 429 in VBA, or forms will display a red X or an empty rectangle where the control should be.
In the same ActiveX Settings panel, select "Prompt me before enabling all controls with minimal restrictions" and click OK. This restores pre-2024 behavior.
For organization-wide deployment, IT admins can set this via Group Policy:
:: Group Policy path:
User Configuration > Administrative Templates > Microsoft Office 2016
> Security Settings > ActiveX Settings
:: Registry equivalent:
HKCU\Software\Policies\Microsoft\Office\16.0\Common\Security
Value: "DisableAllActiveX" = 0 (DWORD)
Microsoft disabled ActiveX for a reason. ActiveX controls run native code inside the Office process with the user's full permissions. They've been a malware vector for decades. Microsoft has stated that ActiveX is a deprecated technology and future Office versions may remove support entirely.
Re-enabling ActiveX keeps your legacy files working today, but it's borrowing time. Every Office update brings the risk that Microsoft will tighten restrictions further.
Not all Error 429 triggers involve OCX controls. If your VBA code uses CreateObject to automate another application, that application must be installed:
' These all require the target app to be installed:
Set outlookApp = CreateObject("Outlook.Application")
Set wordApp = CreateObject("Word.Application")
Set pdfDoc = CreateObject("AcroExch.PDFDoc") ' Requires Adobe Acrobat
Set conn = CreateObject("ADODB.Connection") ' Requires MDAC/ADO
Check that the referenced application is installed and is the same bitness as your Office installation. A 32-bit Office cannot automate a 64-bit Outlook, for example.
For ADODB.Connection errors specifically, the fix is usually re-registering the MDAC components:
regsvr32 "C:\Program Files (x86)\Common Files\System\ado\msado15.dll"
If you're going to fix this properly rather than patching around it, here are the most common legacy controls and what to replace them with:
| Legacy Control | Modern Replacement | Notes |
|---|---|---|
| Calendar Control (MSCAL.OCX) | Native DatePicker or MonthView UserForm control | Removed from Office after 2010; no 64-bit version exists |
| MSCOMCTL TreeView | ListBox with indentation logic or .NET TreeView via COM interop | 32-bit only; frequently corrupts in shared environments |
| MSCOMCTL ListView | ListBox with column simulation or MSForms ListBox | Same OCX as TreeView; both fail together |
| MSFlexGrid | Excel range embedded in UserForm or custom grid class | No 64-bit version; VB6-era control |
| MSCOMCT2 DateTimePicker | Native date input with InputMask or API-based picker | 32-bit only; common in Access forms |
| RichTextBox (RICHTX32.OCX) | WebBrowser control with contentEditable HTML | RTF formatting can be handled via HTML |
When you hit Error 429, work through this in order:
C:\Windows\SysWOW64 (32-bit) or C:\Windows\System32 (64-bit)?regsvr32 from an elevated command prompt.Every fix above is a band-aid. The underlying problem is that ActiveX is a 1990s technology that Microsoft is actively deprecating. Each year brings more restrictions, more blocking, and less support. The only permanent fix is to remove ActiveX dependencies from your files.
For a handful of files, you can do this manually: open each form, delete the ActiveX control, add a native replacement, and rewire the VBA event handlers. For dozens or hundreds of files, that's weeks of tedious work.
That's the problem LegacyLeaps was built to solve. The scanner identifies every ActiveX dependency across all your files in minutes, maps each one to a modern replacement, and shows you exactly what needs to change before you spend any money on conversion.
Download LegacyLeaps and scan your files for free. See every ActiveX control, every missing reference, and get a clear migration path. Use code FIRSTFILE for a free file conversion.
Download Free ScannerPractical fixes for legacy Excel and Access problems. No spam.
Related Articles