I think this scenario exactly illustrates the problem of using inheritance.
In the CLR you only have one base class, so you must choose wisely. Pigeonholing
people into an inheritance scenario to use common functionality imposes too
much of a constraint in a single inheritance world. You've been forced to
forgo one library for another given these constraints. C'mon guys, OOP is
long dead. ((I know I'm going to get a rise for that one!))
And to preempt any flames (hey, I'm a C++ guy originally), my point is that
OOP is not a panacea for reuse (especially in the CLR). It *does* have a
place (despite my jab from above), but there are many other reuse mechanisms
available too that are sometimes more flexible.
-Brock
DevelopMentor
http://staff.develop.com/ballen "Peter Rilling" <pe***@nospam.rilling.net> wrote in message
news:O3**************@TK2MSFTNGP10.phx.gbl...
I don't understand how not using code-behind solve the limitations of
inheritance.
I'm not. I am just trying to see how this would affect me.
I want to be able to use this control and this is how it is set up by
Andy.
I assume there must be some way around this and I am just trying to
see what that is? As I said I am not trying to get into the
behind/inside discussion. It has already been done.
But that doesn't solve my problem if I go to code-behind and then want
to use this control in a bunch of my pages.
In my post in another section it was mentioned I could inherit from
the other class. I am just not sure how I would do that.
Tom
"tshad" <ts**********@ftsolutions.com> wrote in message
news:#F**************@TK2MSFTNGP14.phx.gbl...
Not to get into the code-behind/code-inside discussion again, this
would
be
another reason to not go code-behind. I happen to want to use Andy
Smiths
control. If I were using code-behind and inheriting my page, it
would be
difficult to use his object (at least it seems that way).
Tom
"Brock Allen" <ba****@develop.com.i_hate_spam_too> wrote in message
news:37*********************@msnews.microsoft.com. ..
Nope, in the CLR (and thus ASP.NET) we only have single
inheritance.
-Brock
DevelopMentor
http://staff.develop.com/ballen
> I have a control that I am using from Metabuilders that requires
> you to use:
>
> <%@ Page Inherits="MetaBuilders.WebControls.DialogPage" %>
>
> How do I inherit my code-behind page or another object that may
> require an inherit also?
>
> Thanks,
>
> Tom
>