Formular una preguntaFormular una pregunta
 

Respuesta propuestaWindows Designer Question

  • sábado, 20 de junio de 2009 0:26NewtoLinq Medallas del usuarioMedallas del usuarioMedallas del usuarioMedallas del usuarioMedallas del usuario
     
    Hi,

    I am new to WPF and i have downloaded the trial versions of the Microsoft C# Express.
    I created a new project and on the Windows i tried to drag and drop more than more control it would not allow me to.
    But when i added a Grid Control it lets me add more than one control to the Window ? Why is this so ?

    Also whenever i runt the application and return to the designer pane it shows me a message saying that "An assembly or related document has been updated
    which requires the designer to be reloaded.Click here to reload". Can somebody explain this to me.


    Any help is greatly appreciated cos i am just learning WPF.

Todas las respuestas

  • martes, 30 de junio de 2009 0:50Mark Wilson-ThomasMSFT, ModeradorMedallas del usuarioMedallas del usuarioMedallas del usuarioMedallas del usuarioMedallas del usuario
     Respuesta propuesta
    Hi NewtoLinq

    The Window control in WPF is a ContentControl, which means it can accept one and only one child control. In addition it provides no real layout capabilities. The Grid, by contrast, can accept any number of children and provides comprehensive layout capabilities.

    This is why in the default Window template for WPF (and in fact in other templates for ContentControl roots such as UserControl) we always provide you with a layout container (the Grid) as a child element.

    The "gold bar" you are seeing on compile and run is a consequence of assemblies that your application depends on being updated during compilation. In future releases of Visual Studio we are working on substantially reduce the occasions on which you'll see this "gold bar".

    Thanks, and good luck in your WPF learning endeavours. We look forward to your feedback on the WPF and Silverlight Designer in Visual Studio as you learn. If you have the chance to try out the Beta editions of Visual Studio 2010, you should find they contain many more tools for the beginning user to get started.

    You may also want to check out the new resources over at http://windowsclient.net/wpfdesigner/default.aspx if you decide to explore Visual Studio 2010 Beta 1.

    Mark
    Mark Wilson-Thomas - Program Team - WPF & SL Designer for Visual Studio - posts are provided 'as-is'