title: Layout navigation window
body: <p>I would like to build a WPF window application using the following layout structure. Consider title and button on left hand frame/window like "Master Pages" in ASP.Net. On the right hand frame it should be a WPF navigation window.</p>
  
  <p>When I include Navigation Window as an UI element at the last stack panel, it throws me and error. How should I design the entire layout according to the image screenshot below? Thanks </p>
  
  <pre><code>&lt;Window x:Class="MainWindow"
       xmlns:local="clr-namespace:ClientSocket"        
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      Title=" Desktop" Height="841" Width="1271" WindowStartupLocation="CenterScreen" WindowState="Maximized"&gt;
      &lt;DockPanel&gt;
          &lt;StackPanel DockPanel.Dock ="Top"  Orientation="Horizontal" Background="Red"&gt;
              &lt;TextBlock  Background="red"  FontSize ="36" Width="482" &gt;
             Main Title
              &lt;/TextBlock&gt;          
          &lt;/StackPanel&gt;
          &lt;StackPanel Background="LightGray" DockPanel.Dock ="Left" Width="145"&gt;
              &lt;Button Content="Button1" Name="btnAndroid" Width="119" Margin="3" BorderBrush="{StaticResource {x:Static SystemColors.InfoBrushKey}}" /&gt;
              &lt;Button Content="Button2" Name="btnDownloads" Width="119" Margin="3" BorderBrush="{StaticResource {x:Static SystemColors.InfoBrushKey}}" /&gt;
              &lt;Button Content="AddNewDownloads" Height="37" Name="Button1" Width="133" /&gt;
          &lt;/StackPanel&gt;
          &lt;StackPanel&gt;
          &lt;NavigationWindow Height="auto" Width="auto" Name="nwMain" VerticalAlignment="Stretch" HorizontalAlignment="Stretch" BorderBrush="Blue" BorderThickness="1"  /&gt;
          &lt;/StackPanel&gt;
      &lt;/DockPanel&gt;
  &lt;/Window&gt;
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/vf8Hf.png" alt="enter image description here"></p>