I want to use MSCOMM control in my MS Excel 2010 VBA. The control shall appear in Tools-> Additional Controls dialog box in VBE of MS Excel 2010.

I am trying to register MSCOMM32.OCX on my 64-bit Windows 7 machine. However, as I try to register it using regsvr32 as shown in the command window below, I am getting shown error popup.

enter image description here

What am I missing here? Why is this component not getting registered?

Or this is not the correct way to include MSCOMM control in MS Excel VBA?

I have read following:



But to no avail.

  • Why do you want MSCOMM32.OCX? If it's for a calendar date picker there are better methods. – user156294 Nov 25 '12 at 23:48
  • MSCOMM32.OCX is used for serial communication. My application would be a simulator made in MS Excel. It communicates over serial channel of the computer. – Jay Nov 26 '12 at 3:18
  • @Jay - Its also a 32-bit module which cannot be loaded into a 64-bit process. You are likely using 64-bit version of Excel if your getting this error. – Ramhound Nov 28 '12 at 5:04

Put your ocx control to C:\Windows\SysWOW64 and try to re-register it in that location with the 32 bit regsvr32:

C:\Windows\SysWOW64\regsvr32 C:\Windows\SysWOW64\MSCOMM32.ocx

If it doesn't work: you could try to pick a different version. you could also check if it has all its dependencies already installed.

  • The same is not working. :( – Jay Nov 25 '12 at 17:01
  • How to check of all dependencies are already installed? – Jay Nov 25 '12 at 17:02
  • 1
    @jay, did you copy the whole command line? Salaros is advising you to also use the 32 bit version of regserver. – SeanC Nov 26 '12 at 12:24
  • 1
    The CMD prompt needs explicitly to be started with "Run as Administrator" and full paths used to make absolutely sure that the 32 bit versions are used. And, of course, it will only work with the 32-bit version of Excel. – Tonny Sep 5 '13 at 9:22

Here is what I have read about mscomct2.ocx. I have not verified anything.

mscomct2.ocx is an activex calendar control. You can obtain an up to date version of mscomct2.ocx from http://activex.microsoft.com/controls/vb6/mscomct2.cab.

32-bit windows, such as XP, have mscomct2.ocx in c:\windows\system32.

For windows 64-bit you need to put mscomct2.ocx in a different directory, c:\windows\syswow64.

In conflict with the above paragraph, I have also read that you need to put the MSCOMCT2.OCX in the same folder as your program. Eg. if your program is in C:\MyApp folder, then put the MSCOMCT2.OCX file in C:\MyApp folder too.

Once the mscomct2.ocx file is installed, it needs to be registered. You can use the Microsoft Register Server (Regsvr32.exe) to register a 32- bit .ocx file manually on a 32-bit operating system. You must run regsvr32 as admin.

In conflict with the above statement from support.microsoft.com, this works on a 64-bit system as long as the ocx file is in the syswow64 directory.

If you have obtained the file and registered, yet still have problmes, it might help to first unregister, then register:

regsvr32 /u mscomctl.ocx

regsvr32 mscomctl.ocx


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy