Installing COMCTL32.OCX and MSCOMCTL.OCX on a Windows XP Machine

I recently had to install the Microsoft Common Controls on an XP machine that had never had this stuff installed before… Probably these files were missing because this machine had never had Microsoft Office, or VB, or Visual Studio, or whatever suite installs these items.

I needed these files to run a FoxPro app that I had written which used the TreeView control from the VB6/MSCOMCTL.OCX library.

Here is what I learned and how I got it working:

Getting started

 Note: There are TWO Common Control libraries out there. You must figure out which one you need.

1. The older VB 5 Common Controls (COMTL32.OCX)

     and

2. The newer VB6 Common Controls (MSCOMCTL.OCX):

Regarding the older COMCTL32.OCX (VB5 era) versus the newer MSCOMCTL.OCX from VB6 era, one user on StackOverflow had this to say:

“The earlier Common Controls 5.0 (comctl32.ocx) has better compatibility with XP/Vista than the Common Controls 6.0 (mscomctl.ocx). I suggest using it instead” – rpetrich Aug 13 ’09 at 0:44

Step 0: Before installing either of the Microsoft Common Controls you must have the following versions of the Automation system files on your system:

OLEAUT32.DLL     2.20.4054 or greater
COMCAT.DLL        4.71 or greater
OLEPRO32.DLL    5.00.4055 or greater
ASYCFILT.DLL    2.20.4056 or greater
STDOLE2.TLB        2.20.4054 or greater

You may or may not have these files on your system already. I really don’t know how these files generally get installed on a new system; if they are part of the main OS install, or if they get installed with other common Microsoft suites. My guess is that if you have Office 97, Visual Basic 5.0, Visual Studio, Internet Explorer, or Visual C++, etc, you should already have these Automation system files.

Either way, if you do not have these files on your system, you must first download and install them as documented in the following Microsoft Knowledge Base article:

Download here: http://support.microsoft.com/kb/180071/EN-US
(Default download filename will be named Msvbvm50.exe)

1. For the older VB 5 Common Controls (COMTL32.OCX):

Follow Step 0 above.
   
Once you are sure you have the correct Automation system files on your computer, you can install COMCTL32.OCX by executing COMCTL32.EXE. This will install the following files:

COMCTL32.OCX    5.00.3828    Updated ActiveX control
COMCTL32.DEP    5.00.3828    Dependency info for Visual Basic 5.0 Setup Wizard
MSSTKPRP.DL      5.00.3714    Design-Time Stock Property Pages

The setup program does not install a *license* to use COMCTL32.OCX for development. You must already have a license installed on your system by one of the products listed in the applies to section above in order to COMCTL32.OCX for development.

Download the COMCTL32 install package here:
http://download.microsoft.com/download/win95upg/update/1/w97/en-us/comctlzp.exe

The default download filename will be comctlzp.exe.
Note: You must then unzip this exe to get the actual installable exe file.
  

2. For the newer VB6 Common Controls (MSCOMCTL.OCX):

Follow Step 0 above.

As far I could determine, there is no official download link from Microsoft for MSCOMCTL.OCX. You can find tons of free download links all over the internet, but those sites always scare me as they might contain viruses or malware.

I learned a lot about the issues around getting the files downloaded and installed here:
http://stackoverflow.com/questions/1226319/whats-the-proper-source-for-windows-common-controls-6-0-component-mscomctl-ocx
   
So, based on the info on the above post, here is what I did:

  1. Locate this file (MSCOMCTL.OCX) on some other XP machine that already has the file. Path is C:\Windows\System 32.
  2. Copy this file to the same path C:\WINDOWS\SYSTEM32 on the new machine.
  3. Register the file by running ‘regsvr32 C:\WINDOWS\SYSTEM32\MSCOMCTL.OCX’ at the command window. (Admin right are probably required.)
  4. Reboot.

   
   

If you have any corrections or additional instructions to share, please add a comment so we can get this reference as correct as possible.

5 thoughts on “Installing COMCTL32.OCX and MSCOMCTL.OCX on a Windows XP Machine

  1. Satish Thakur

    Dear,
    While installing Windows DLL or component through winetricks in ubuntu 12.04 it gives error like sha1sum mismatch! Rename /home/sysadmin/.cache/winetricks/comctl32/cc32inst.exe.

    Anybody resolved this error then please send me resolution.

    thanks in advance.

    Reply
  2. admin Post author

    You are welcome to ask this question here, however the question is not even related to the subject of the post.
    My blog is not a general help forum, so you should try to find a better place to post this question, where you stand a real chance of getting help.

    Consider using StockOverflow to post this question. http:www.stockoverflow.com

    Reply
  3. Mike

    I have found that the following works:

    -Download the MS VB6 Common Controls installer from Microsoft
    -Open the executable with an archive manager such as 7-Zip (yes, it works)
    -Copy mscomctl.ocx from the executable to %SYSTEMROOT%\system32\
    -run regsvr32 mscomctl.ocx

    This method worked after running the installer itself failed. (!) I was trying to get Dexpot, the virtual desktop software, to work on Windows XP, but the VB6 installer merely told me to reboot my computer, without installing anything.

    Don’t know how much longer this trick will be relevant, seeing as XP will no longer be supported with security updates as of 2014 (last I heard), but if you believe the stats, some 37 percent of desktops are still using XP!

    Reply
  4. Raj

    We have four different versions of mscomctl.ocx in our win 2003 environment. I’m not sure where these files are originated from… Can anyone advise if this part of windows 2003 OS installation or what are possibilites.

    Verions : 6.1.95.45, 6.1.97.82, 6.1.98.33 and 6.1.98.34

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>