-
We do exactly what you need to do, but we use ActiveX DLL's. This way you can say:
Code:
objWhatever = CreateObject("DLLName.ClassName")
I don't know enough about straight forward C++ to say this for certain, but I think you can achieve this by using a type library:
Code:
//-------------------------------------------------------------------
// IMainForm
//-------------------------------------------------------------------
[
odl,
uuid(06CFF40F-A63B-11D3-8476-00E029423382),
version(1.0),
dual,
nonextensible,
oleautomation
]
interface IMainForm : IDispatch {
[id(0x01), propget]
HRESULT Window([out, retval] IWindow** retval);
};
In the simple example above, I think that the use of the word "oleautomation" makes this class creatable with VB's "CreateObject" function.
Hope this helps.
Shrog
-
On second thought, I'm totally wrong. You cannot create an object using a TLB.
The fact is that the DLL is not a COM object, so you would not be able to use it dynamically in VB, only staticly.
Shrog
-
The problem is: The dll's are not mine..!
I'll see what I can come up with... and perhaps I'll just write a c++ dll that will call the dll's for me... that way it should work (I hope)
Gerco.