Adding Controls to SideBar Example

Wizard for WPF Forum

Posted 14 years ago by Harry Whitehouse
Version: 9.2.0515
Hi There!

I'm still trying to wrap my head around the WPF coding model so here's another newbie question:

I have the Sample Browser project up -- it compiles fine and I've been tweaking some of the XML to observe the responses. In particular, when I have the MainControl.xaml for the Sidebar example in the designer, I try to drag over a control (e.g. a button or textbox) from the toolbar and nothing seems to happen. The design screen dims a bit when I release the control on the wizard page, but when the screen returns to normal I don't see the control.

I have another start-from-scratch project where the Wizard is placed on a default Window which is created when the project is initiated. On that project, I seem to be able to add controls at will to various wizard pages.

Obviously, I'm missing something basic here and I would be grateful if someone could steer me in the right direction.



P.S. From the Sample Browser project, it appears that one might be able to create a wizard application WITHOUT an underlying main window. Is that true and what are the implications with or without the main window.

Comments (1)

Posted 14 years ago by Actipro Software Support - Cleveland, OH, USA
Hi Harry,

The VS designer requires a Panel to be present to be able to drop controls. In that QuickStart we have a TextBlock as a direct child of the WizardPage. If you surround the TextBlock with a Grid, thereby having a Grid as the child of the WizardPage, then you can drag controls onto it.

For your second question, Wizard is just a WPF control. So it can be used on a Window (which it generally is the direct child of a Window) or can be used other places too. Just remember that the Window is what provides the title bar, etc. and is the top-level container for any WPF content.

Actipro Software Support

The latest build of this product (v24.1.2) was released 26 days ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.