By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,968 Members | 1,871 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,968 IT Pros & Developers. It's quick & easy.

COM-interface and inheritence

P: n/a

I want to build a class library with baseclasses. The classes that inherit
from these baseclasses will get a COM-interface. I use the following way:
REM BaseClass.dll:
Interface_MyBaseClass ' No COM-interface here.
End Interface

Class MyBaseClass
Implements _MyBaseClass
MyMethod() Implements _MyBaseClass.MyMethod
End Class
REM Class.dll:
Interface _MySuperClass ' COM-interface.
Inherits _MyBaseClass
REM Other functionality.
End Class

Class MySuperClass
Inherits BaseClass
Implements _MySuperClass
REM Other functionality.
End Class
I 'regasm.exe' the library with the COM-interface and 'copy-local' the
library with the baseclasses.
Works for .NET clients, but not for COM-client. The COM-client can see the
library and make a reference to it. Intellisense sees the class, but only
the functionality that is not in the baseclass. Whenever you try to make a
new object of the class, the program crashes. As though the program cannot
find the library with the baseclasses.

Anyone any idea what is going wrong?

Nov 21 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.