Excel - Run-Time Error '424' Object Required

Posted by Blake on 12/17/2014
)
Excel - Run-Time Error '424' Object Required

Today I was troubleshooting an Excel worksheet that worked on some workstations but not on others. The "Run Time Error 424" occured when a button was referenced in a VBA macro (in this case the button was called by name and the enabled property was set to true or false based on some criteria in the sheet). I also noticed that I was able to drag new Excel buttons onto the worksheet but whenever I would drag an ActiveX button (or any ActiveX control) I would get an object error.

I believe the reason this works on some workstations and not others is that the ActiveX controls for those form controls exist on some and not other workstations. To work around the issue I deleted the ActiveX button from the worksheet, added an Excel button and assigned the macro to the Excel button that the old button ran. This allowed the button to work on all workstations that have opened the file.

Note:

In order to insert a form control you may need to enable the developer ribbon tab if you haven't already enabled it. To do this follow these steps:

  1. On the file tab, choose Options
  2. Choose "Customize Ribbon" on the Options tab
  3. In the "Main Tabs" set of check boxes check the "Developer" box