Tabbed Interface

Topics: Questions
Aug 10, 2012 at 8:01 PM

I am trying to create an MVVM/WPF application using Catel that has a UI that is similar to Visual Studio.  I would like to have a TreeView containing items off to the side and then when the user clicks on of them, open a "window" in a tabbed interface that takes up the rest of the screen.

The tricky part is that I would like the individual views in the tabs to each have their own set of OK/Cancel or Save/Cancel buttons along with their own InfoBarMessageControl to display validation issues.

I know that the DataWindow offers this functionality, but it can't be hosted in a TabControl.  Is something like this possible using the Catel UserControl?

Aug 11, 2012 at 11:19 AM

Yes, this is possible. I recommend AvalonDock for the tabbed behaviors. Then you can create your own DocumentContent base class and embed the InfoBarMessageControl.

Catel contains the WrapControlHelper class which Catel uses internally to wrap the content in the InfoBarMessageControl. Simply override OnContentChanged like the DataWindow does.