MSComctlLib reference/components load with "was not a loaded control class" error

12,112

If you don't have the common controls selected in your project, but the controls are on a form, then you'll receive these errors when you try to load the project (or add a pre-existing form to a project that doesn't have the component selected).

On the VB6 menu, select Project-Components. Scroll down to Microsoft Windows Common Controls 6.0 (if you have a service pack installed, then the SP level will usually be at the end of the library name). Select that component, click Ok. Save the project, and then reload the project.

If this is the source of your issue, you should now be able to load those forms that have a reference into the common controls.

Share:
12,112

Related videos on Youtube

Igor Tenório
Author by

Igor Tenório

Updated on June 04, 2022

Comments

  • Igor Tenório
    Igor Tenório almost 2 years

    I'm having trouble oppening an project developed in VB6. Some controls attached with MSComctLib class are not loading.

    I'm using Windows 7.

    In the error analysis the following message appears (without the number of lines):

    Class MSComctlLib.ImageList of control ImageList1 was not a loaded control class.
    Class MSComctlLib.Toolbar of control Toolbar1 was not a loaded control class.
    MSComctlLib.StatusBar class of control sbStatusBar was not a loaded control class.
    

    and then a lot of invalid property names,

    Ex:

    The property name _ExtentX in ImageList1 is invalid
    The property name Buttons in Toolbar1 is invalid
    ...
    

    According to the guidance of microsoft support site http://support.microsoft.com/kb/896559, an update would be the solution http://www.microsoft.com/en-us/download/details.aspx?id=10019

    I tried running the executable VisualBasic6-KB896559-v1-ENU but I still have the same error when opening the project.

    Could someone tell me how to solve it?

    Thanks in advance!

  • Igor Tenório
    Igor Tenório about 6 years
    I tried to do as explained above, but when applying Microsoft Windows Common Controls this message appears: '' could not be loaded location: c: \ windows \ syswow64 \ mscomct.ocx
  • Siyon DP
    Siyon DP about 6 years
    Did you see this?
  • Igor Tenório
    Igor Tenório about 6 years
    I tried to follow this instructions, but not work. regsvr32 MSCOMCTL.OCX regtlib msdatsrc.tlb
  • Igor Tenório
    Igor Tenório about 6 years
    Some information about MSCOMCT.OCX: INF file for MSCOMCTL.ocx [DefaultInstall] CopyFiles=install.files RegisterOCXs=RegisterFiles [DestinationDirs] install.files=11 [install.files] MSCOMCTL.OCX=MSCOMCTL.OCX [RegisterFiles] %11%\MSCOMCTL.OCX [MSCOMCTL.OCX] file-win32-x86=thiscab RegisterServer=Yes FileVersion=6,1,97,82 [version] signature="$CHICAGO$" AdvancedINF=2.0 [SourceDisksNames] 1="default",,1