K
Kent Rollins
I am trying to cause a custom Control to paint while that Control is
not a member of Form.Controls. I prefer not to add it to Controls
because I am basically adding functioanlity to the forms designer and
if I add it to the Controls collection, I will have to add a lot of
special handling logic elsewhere in the app to work around the one
special control.
My preference is to create the special Control as a child of the Form
and forward paint messages to it thru any mechanism. I have tried
calling Control.Refresh(), Control.Invalidate(), and Control.Updte()
in the Form.Paint() method, but none of those work if the Control is
not in Controls. If I add the Control to Controls, it works
automatically as it should.
Any pointers on how to get it to paint without adding it to Controls?
Thanks
Kent
not a member of Form.Controls. I prefer not to add it to Controls
because I am basically adding functioanlity to the forms designer and
if I add it to the Controls collection, I will have to add a lot of
special handling logic elsewhere in the app to work around the one
special control.
My preference is to create the special Control as a child of the Form
and forward paint messages to it thru any mechanism. I have tried
calling Control.Refresh(), Control.Invalidate(), and Control.Updte()
in the Form.Paint() method, but none of those work if the Control is
not in Controls. If I add the Control to Controls, it works
automatically as it should.
Any pointers on how to get it to paint without adding it to Controls?
Thanks
Kent