user1782426
user1782426

Reputation: 107

Run-time error 440 VB6

I have created an exe program based on ocx file and I used VB Package & Deployment wizard to install the exe file as a program on a non vb environment, the problem is I am getting this error when running the program

"RUN TIME ERROR '440' AUTOMATION ERROR.

What do you think is the problem?

Thanks

Upvotes: 3

Views: 16095

Answers (1)

Stefan
Stefan

Reputation: 17658

The 440 Automation error usually indicates that one (or more) COM object failed to load.

This might be an ActiveX exe, ocx, or maybe one of the external dependencies you included in your project.

Make sure all the external libraries you use are registered correctly on the system that's giving the error.

You can test this by registering the ActiveX (.ocx, .exe), and COM components (usually .dll) manually.

ATL/COM, ActiveX EXE, OCX, DLL

If the target assembly is a COM/ATL assembly, you can use regsvr32.exe (located in windows\system32 directory) for the ocx files and the COM- dlls. You can register an ActiveX-exe by running it with the option /regserver see: http://support.microsoft.com/kb/297279 and http://support.microsoft.com/kb/146219

.NET ComVisible

If the target assembly is a .net assembly which uses ComVisible, you can register it with regasm.exe, it is somewhere in the .NET framework directory. see: How to register a .NET assembly as COM?

Or else

You might want to use a tool like dependency walker to check which registration and dll's are missing from your system.You can download it from here, http://dependencywalker.com/ beware, run downloaded exe's at your own risk.

Upvotes: 4

Related Questions