UserControl inheritance not working as expected
- From: ian.kemp@xxxxxxxxx
- Date: 29 Nov 2006 02:16:03 -0800
I have a ReforecastCurvesControl class (inherits from UserControl)
which contains a TableLayoutPanel. The TableLayoutPanel contains 3
controls: a graph control that does custom painting and 2 Groupboxes.
These controls are all set to "protected".
We want to re-use the ReforecastCurvesControl in our project, because
at least 3 of the screens are very similar. However, when creating a
new UserControl that inherits from ReforecastCurvesControl, none of the
controls (TableLayoutPanel or its children) can be modified - their
properties are grayed-out, they can't be moved, you pretty much can't
do *anything* with them. Not only that, new controls can't be added to
the inherited control.
The strange thing is that one GroupBox contains 2 RadioButtons and a
Button, also set to "protected", and the properties of these controls
are fully editable; while the other contains a "protected"
DataGridView, which is completely non-editable.
Removing the TableLayoutPanel (so that the graph control and GroupBoxes
were sitting on the base UserControl) allows me to edit everything,
*except* the DataGridView. Since the DataGridView is probably the main
control that subclasses need to customise, this doesn't really help.
I'm tearing my hair out over this, my PM and Supervisor are as lost as
I am and a deadline is fast approaching. Somebody, please help!!!
.
- Next by Date: Re: 3rd Party Control Property Grid.
- Next by thread: Re: 3rd Party Control Property Grid.
- Index(es):