Igor

Igor

  • NA
  • 1
  • 0

Listening on a non-default source interface

Mar 29 2009 6:45 AM

Hello,

I've got a CoClass that implements several connction-point interfaces, like this:

 coclass MyCoClass
 {
  [default] interface IMyIntf;
  [default, source] dispinterface _IMyEvents1;
  [source] dispinterface _IMyEvents2;
 };

C# (VS2008) builds correct wrapper for the dispinterface marked as "default source":

  public interface _IMyEvents1
  {
    event IMyEvents1_someHandler;

   //...etc...
  }

But how can I force it to build similar wrappes for non-default event interfaces?

I could write them manually, but these files are read-only and seem to be re-generated by the IDE.

Thanks!