P
Peter Morris [Droopy Eyes Software]
Hi all
I have a few questions regarding composite controls
1) My composite controls are created based on a property of my control.
When the postback of a page occurs due to a button click, my
CreateChildControls() method is called before the button code is executed,
so if that button code changes the property in question it is already too
late to reflect this in the control. Is there a way to "Invalidate" my
control when this property is set so that it's child controls are recreated?
2) Dropping my component on to a WebForm reveals two behaviours which I do
not want.
2a) Firstly the control has a specific width/height, whereas I want it
to size automatically based on which of the child controls are visible.
2b) At design time, none of the child controls are visible at all
3) My final question. One property of my control is a DateTime. If I allow
data binding to this property how do I handle a null value from the data
source? I have an IsNull property, but surely the data binding will try to
bind the DateTime to null?
Thank you
I have a few questions regarding composite controls
1) My composite controls are created based on a property of my control.
When the postback of a page occurs due to a button click, my
CreateChildControls() method is called before the button code is executed,
so if that button code changes the property in question it is already too
late to reflect this in the control. Is there a way to "Invalidate" my
control when this property is set so that it's child controls are recreated?
2) Dropping my component on to a WebForm reveals two behaviours which I do
not want.
2a) Firstly the control has a specific width/height, whereas I want it
to size automatically based on which of the child controls are visible.
2b) At design time, none of the child controls are visible at all
3) My final question. One property of my control is a DateTime. If I allow
data binding to this property how do I handle a null value from the data
source? I have an IsNull property, but surely the data binding will try to
bind the DateTime to null?
Thank you