Question

I have two test machines say machine A and B (both 64 bit) .There is a VB6 application which uses the Vbsql OLE Custom control module (Vbsql.ocx).

That VB application runs fine without any errors in machine A but it fails with the below error message when executed in Machine B.

enter image description here

Note: I copied the ocx file from machine A to register it on machine B but it couldn't be registered the error screenshot is like below.

enter image description here

Both machines doesn't have VB6 IDE so I could be able to debug.

Was it helpful?

Solution 2

I found a way to register the VBSQL.OCX file.

Using dependency walker I figured out NTWDBLIB.dll file is missing in machine B so copied into SYSWOW64 folder and registered using the elevated command prompt.

OTHER TIPS

Have you tried running the 32-bit version of regsvr32?

%WINDIR%\...\SysWOW64\regsvr32 vbsql.ocx

The 64-bit version won't load this (presumably) 32-bit DLL.

You can put the ocx file in the same directory as your executable.

Use following Run command in order to register OCX

Use following Run command in order to register OCX

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top