|
-
Jun 26th, 2006, 11:32 AM
#1
Thread Starter
Junior Member
Making OCX within ActiveX DLL/EXE available to Standard EXE
If I create an ActiveX Control (OCX) and compile it, then open a standard EXE and add that from Components, I can then use that User Control in my project as I like.
So far, so good.
However, I now want to create an ActiveX EXE or DLL that includes multiple User Controls (ActiveX Controls), so that I only need one reference and all the components show in the IDE for me to drag into my Standard EXE's form.
So to try and do this I have created an ActiveX DLL, added 2 User Controls within that, and compiled it. BUT, when opening a Standard EXE and referencing the dll (that contains the Controls), I do not get the controls added to the Component bar (for me to drag onto a form and use).
I know this is possible because there are dlls out there which do exactly this (and also components that contain multiple controls - such as MS Windows Common Controls).
So what further steps do I need to include to get these to show?
-
Jun 26th, 2006, 11:59 AM
#2
Re: Making OCX within ActiveX DLL/EXE available to Standard EXE
It shlouldn't be in a DLL.... they should be in an OCX.
You need to create an ActiveXControl project and put them in there.
-tg
-
Jun 27th, 2006, 04:31 AM
#3
Thread Starter
Junior Member
Re: Making OCX within ActiveX DLL/EXE available to Standard EXE
While I appreciate that what you suggest is what I would do myself usually, let me explain what I am trying to solve and why I would like an answer to my origional question (even if the answer is that this is not possible in VB6):
My colleague uses C++ and he writes several controls. I usually get groups of controls within a single ActiveX DLL from him. When I reference these, they appear in my component bar for me to use. I have done this with several controls in the past and this works fine.
However, my understanding of C++ is as "good" as his understanding of VB6 (i.e. we can sort of follow each other's language for debugging, but could not quickly write code without looking through reference every 5 minutes!).
In the latest attempt he has a server where he only needs a single instance, but multiple controls (each giving different views and information) talk to that server. The server and the controls are all packaged in one dll as usual. This time it will not work when trying to use it in VB6 (Gives error along the lines of not being able to load the file).
So to solve this I need to understand how this is done in the first place, which is why I was trying to create a similar DLL in VB6.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|