title: Escape from DataContext
body: <p>I have a window that get its data from another class that is passed as DataContext. But I now also want to do data binding within the window. The window looks as follows:</p>
  
  <pre><code>&lt;Window x:Class="WpfApplication1.Window1"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      Title="Window1"
      Height="300"
      Width="300"&gt;
      &lt;StackPanel&gt;
          &lt;TextBlock Text="{Binding UserName}" /&gt;
          &lt;TextBlock x:Name="TestTextBlock"
                     Text="Hello World" /&gt;
          &lt;TextBlock x:Name="TestTextBlock2" 
                     Text="{Binding ElementName=TestTextBlock,Path=Text}" /&gt;
      &lt;/StackPanel&gt;
  &lt;/Window&gt;
  </code></pre>
  
  <p>The binding between the text blocks TestTextBlock and TestTextBlock2 works fine, but only until I change the DataContext-property of the window. How can I bind between those two textblocks so that changing the DataContext will not break the data binding?</p>
  
  <p>Thanks in advance,
  Stefan</p>