I have migrated an ActiveX MFC control from VC6 to VS2017-v141. It compiles in both 64 and 32 bit. I need for my host MFC application the 64-bit version of the control.
The ActiveX component (XButton.ocx) registers without a problem, both as 32-bit and 64-bit versions (with the right regsvr32.exe of course).
I have used the Active-X wizard in VS2013 to generate the classes for it in the host application (VS2017 lacks the wizard). I need to select the component as dll-file, as in the list of registered activeX components, the XButton ActiveX component is missing.
The classes are generated and I can use the component in the designer. But on runtime the application crashes at instantiation of the ActiveX component. Also I tried to use the component in a forms application, but it is not visible as COM component in the toolbox->Choose item… dialog.
Anyone an idea to solve this?
The registration of the ActiveX component (from command prompt):
Source: Windows Questions C++