[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Cannot Create Simple 32-Bit COM Component on 64-Bit Windows

Posted on 2014-04-09
2
Medium Priority
?
1,056 Views
1 Endorsement
Last Modified: 2014-04-10
Hi.  I have an ATL/MFC COM simple object written in Visual C++ 6.0.  This COM object has a single method, Test(), that simply calls the MFC MessageBox() method to display a "hello world" message.

I am trying to use this COM object on 64-bit Windows 7.  I put the file for this COM object, TestLibrary.dll, into the SysWOW64 folder and ran as an administrator the command "regsvr32 C:\Windows\SysWOW64\TestLibrary.dll", which resulted in the following message: "DllRegisterServer in C:\Windows\SysWOW64\TestLibrary.dll succeeded."   When I try to create the COM object, for example in Microsoft Excel, however, I get the following error message: "Run-time error '429': ActiveX component can't create object."  Do you have any ideas as to why I cannot create the COM object on 64-bit Windows?  It works flawlessly on 32-bit Windows.

Thank you.
1
Comment
Question by:deatc
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 40

Accepted Solution

by:
Jacques Bourgeois (James Burger) earned 1200 total points
ID: 39990389
If you are using the 64-bit version of Excel, you will have problems communicating with many 32-bit dlls. This is why Office usually installs the 32-bit version by default, even on 64-bit computer.

This is not a problem with Office, this is a normal problem with 64 bit applications, that use values that are too big for 32-bit dlls and applications.
0
 
LVL 86

Assisted Solution

by:jkr
jkr earned 800 total points
ID: 39990477
There is a little caveat with 'regsvr32.exe' on Win64 - the you need to specify the FULL path when calling it to register 32bit DLLs, i.e.

C:\Windows\SysWOW64\regsvr32.exe C:\Windows\SysWOW64\TestLibrary.dll

Open in new window


BTW, 'C:\Windows\SysWOW64\regsvr32.exe' might not be the accurate full path to that executable, this is a 32 bit laptop 'm posting from and I can't verify this therefore, but  am sure you'll find out the right one :o)
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
Container Orchestration platforms empower organizations to scale their apps at an exceptional rate. This is the reason numerous innovation-driven companies are moving apps to an appropriated datacenter wide platform that empowers them to scale at a …
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question