PDA

Click to See Complete Forum and Search --> : Compiling OCX


bmarzouk
Mar 27th, 2001, 04:37 PM
Hello,

I have made an ActiveX control, ofcourse I used a test project while programming the OCX.

Now I have two questions:

First, How to compile the whole project (Test project and ActiveX control) without
having to compile the ActiveX project explicitly and then compile the Test project?

Second, If I want to compile the ActiveX control alone, how to make the Test project refers to
the compile OCX instead of the OCX source (vb ActiveX project)?

Thanks,
Belal Marzouk

HaxSoft
Mar 29th, 2001, 04:23 PM
I think you have to compile the control project first. That produces your OCX file. Just open the control project (.VBP file) instead of the project group (.VBG file) and compile it.

Once the control has been compiled, the control's interface will be in the Windows registry (meaning that VB can find it). So when you open the test project alone (again VBP -- not VBG), go into the Project\Components menu in VB and make sure that the name of your compiled OCX is checked in the list.

This usually happens automatically, but test it just in case. Once you are satisfied that your test project is referencing the compiled version of your control instead of the source-code version, compile the test project.