Re: User Control creating a control dynamically while in designer



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

.



Relevant Pages

  • English eBooks Engineering
    ... Adaptive Voltage Control in Power Systems Fusco, ... Advanced Design Techniques for RF Power Amplifiers Krizhanovski, ... Advanced Fuzzy Logic Technologies in Industrial Applications Bai, ... Bioinformatics Using Computational Intelligence Paradigms Jain, ...
    (sci.med.nutrition)
  • Re: Microchip programmer Sydney Aus
    ... schematic design, embedded firmware and pcb layout to finished product. ... possible through the use of advanced microcontroller products from Microchip ... microcontroller applications in Innovative Power and Control solutions. ... Resources cover a broad range of electronics ...
    (sci.electronics.design)
  • Re: usercontrol with readonly property that can be set at design time
    ... Ultimately I'm trying to find out which label was clicked and show the ... I don't want to do any sort of case statement based on the control ... because as the name suggests the values for such a property are design time ... are use at design time only. ...
    (microsoft.public.dotnet.framework.windowsforms)
  • Ebooks Forum
    ... Analysis and Design of Advanced Multiservice Networks Supporting ... Control and Observer Design for Nonlinear Finite and Infinite ... IUTAM Symposium on Computational Approaches to Multiphase Flow ... Islamic Philosophy and Occidental Phenomenology on the Perennial Issue ...
    (sci.med.nutrition)
  • a forum for you
    ... Advances in High Performance Computing and Computational Sciences ... Analysis and Design of Advanced Multiservice Networks Supporting ... Control and Observer Design for Nonlinear Finite and Infinite ... IUTAM Symposium on Computational Approaches to Multiphase Flow ...
    (sci.med.nutrition)

Loading