Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Hey you Object, Hey you!
Message
From
16/11/2003 11:24:08
 
 
To
16/11/2003 01:00:39
General information
Forum:
ASP.NET
Category:
Migration
Miscellaneous
Thread ID:
00850229
Message ID:
00850436
Views:
18
>>Hold on a sec, correct me if I'm wrong. <
>
>OK, you're wrong. <g>
>
>If I put the following in the Click EventHandler of MyButton:
>
>MessageBox.Show(this.MyButton.Parent.ToString());
>
>it will display the container that the button is contained in, be it a form, a UserControl, a GroupBox, whatever. It does not display the Button class that MyButton is derived from.
>
>This is in WinForms ... now, granted, I haven't done a lot in WebForms but I'm pretty sure that it works the same in WebForms.
>
>~~Bonnie

Well, you learn somethin' every day. I looked at the control class, and the parent property is indeed a reference to the container it is in for both windows and web forms.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform