2
votes

I have developed a C++ DLL-based COM object that implements some IUnknown derived interface. How can I use it in VB6? Does VB6 support IUnknown based interfaces, or I need to derive from IDispatch?

UPDATE

I have not used ATL. The implementation is based on A very simple COM server without ATL or MFC article. Seems like I need to generate a .tlb file for my object?!

2

2 Answers

3
votes

You do not need to use IDispatch; that's only required for late binding.

To use your object you must add a reference to the object's type library to your VB6 project.

3
votes

If the interface is only derived from IUnknown and not IDispatch , you can use early binding in VB6.