Re: User Control creating a control dynamically while in designer
- From: "Bryan Phillips" <bphillips@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Sun, 14 Jan 2007 01:43:53 +0000
Use the DesignMode boolean property from the ISite interface or Component class to detect if the control is being actively designed.
--
Bryan Phillips
MCSD, MCDBA, MCSE
Blog: http://bphillips76.spaces.live.com
"Mark" <mjohnson@xxxxxxx> wrote in message news:umikfhWHHHA.960@xxxxxxxxxxxxxxxxxxxx:
My UserControl needs to dynamically create a contained control based on a
property that is able to be set at design time.
In the constructor for my UserControl it sets up it's default display state
which includes the contained control. Everything works fine when the
default control is created here.
In the designer if I change the property which would change the contained
control to be re-created, the contained control looses the knowledge that
it's participating in design time and defaults to rendering in run time
mode.
Is there a way to tell the dynamically created control that it is
participating in the designer and should render in design time?
Thanks,
Mark
.
- Prev by Date: Re: Property value not saved
- Next by Date: Re: Issue with Custom Designers.
- Previous by thread: Re: Property value not saved
- Next by thread: Re: Issue with Custom Designers.
- Index(es):
Relevant Pages
|
Loading