Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How does Visual Inheritance work in .Net?
Message
From
19/06/2007 13:14:49
 
 
To
19/06/2007 11:15:58
General information
Forum:
ASP.NET
Category:
Other
Environment versions
Environment:
C# 2.0
OS:
Windows XP SP2
Miscellaneous
Thread ID:
01234107
Message ID:
01234324
Views:
14
For Properties for which there is no "system default", then your above steps will not work because the "reset" will be disabled in the Property Sheet ... so it becomes even more important to have a DefaultValue attribute for that Property in your own class.

That's true, but not sure that's applicable to any property that a developer would ever be specifying in a subclassed winform control. I just did a quick scan through all the props that I set in my subclass (and even some that I don't) - for each one, if I override it in my form, and then right-click, reset is available. Since you can drop a label or a textbox on a form, not change ANYTHING, and run it....

But regardless, while not using it probably still provides more than some might first think (how's that for a lawyer-like sentence!), I agree with you, DefaultValue is the best practice.

Kevin
Previous
Reply
Map
View

Click here to load this message in the networking platform