Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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:

Registering OCX file manually

http://social.msdn.microsoft.com/Forums/en/vbgeneral/thread/1f00d6cc-00a9-4ca0-9698-535e2487af31

But to no avail.

share|improve this question

migrated from stackoverflow.com Nov 28 '12 at 4:54

This question came from our site for professional and enthusiast programmers.

    
Why do you want MSCOMM32.OCX? If it's for a calendar date picker there are better methods. –  ooo 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

1 Answer 1

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.

share|improve this answer
    
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. –  Sean Cheshire Nov 26 '12 at 12:24
    
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

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.