Simulating Multiple Inheritance

Aug 26 2004 12:16 AM
Hello, "In COM, multiple inheritance between interfaces is not supported. However, by using the derived members capability, multiple inheritance can be simulated."..MSDN Library I have created an object which involve a datagrid. But when I create a form and try to use the object, I found that some of the property exists for a datagrid does not show in the usercontrol in the form, for example BackgroundColor Property. So i thought of creating properties in my usercontrol, but someone told me there is a better way because by generating properties in the user control, u tend to duplicate. And then i come accross this Multiple Inheritance. And since .Net does not support multiple inheritance, the MSDN Suggest to use the derived members capability. As I read on, they mentioned something about IInterfaceDef2::CreateAlias , but i think they did not provide sample or an example(or at least I cannot find them), thus I cannot imagined how this IInterfaceDef2::CreateAlias supposed to look/be like.. so is there someone who have experience in this IInterfaceDef2::CreateAlias thing? 1) Can you please give me some clues or samples (is better) of this IInterfaceDef2::CreateAlias. :) 2) Or if somene can tell me the proper way to do this(not necessarily the IInterfaceDef2::CreateAlias)? So far the properties that I have created only take effect after the FORM is load, not during Design time like normal Datagrid Properties can do. Thanks.