OK, I see. But when I use this instead of the ComClassAttribute the events
do not show.
> > 3. Can't get the ClassInterface(ClassInterfaceType.AutoDispatch) to
> > work as an alternative to ComClassAttribute(). It is supposed to
[quoted text clipped - 3 lines]
> All members can be accessed late bound, but don't show up in
> browsers. What you want is AutoDual instead of AutoDispatch.
> OK, I see. But when I use this instead of the ComClassAttribute the
> events do not show.
You need to explicitely define interfaces like this
<InterfaceTypeAttribute(ComInterfaceType.InterfaceIsIDispatch)> _
Public Interface TestEventInterface
Sub TestEvent()
End Interface
<ClassInterface(ClassInterfaceType.None), _
ComSourceInterfaces("TestLib.TestEventInterface")> _
Public Class TestClass
Public Event TestEvent()
...
End Class
I don't know if this can be done together with CIT.AutoDual. If you use
CIT.None, you must also explicitely define all interfaces to be exposed
for your class (which must implement them). Only interface members are
then exposed to COM.
Perecli Manole - 30 Aug 2003 07:45 GMT
If one of my functions return a GUID I noticed that the COM wrapper exposes
this type but how can this be used from the COM side when it doesn't know
what type this is. How can I handle conversions from .NET types to COM
types?
Perry
> > OK, I see. But when I use this instead of the ComClassAttribute the
> > events do not show.
[quoted text clipped - 17 lines]
> for your class (which must implement them). Only interface members are
> then exposed to COM.