title: Unable to set ContentTemplate via DataTrigger
body: <p>I want the <code>ContentTemplate</code> to vary according to the value in the <code>DataTrigger</code>.<br>
  And yes, I considered using a <code>DataTemplateSelector</code>, but now I need a <code>DataTrigger</code> or better said a <code>MultiDataTrigger</code>.</p>
  
  <p>Please take a look at the following sample app, the <code>DataTemplate</code> doesn't change:</p>
  
  <pre><code>&lt;Window x:Class="Window1"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:src="clr-namespace:WpfApplication1"&gt;
      &lt;StackPanel&gt;
          &lt;CheckBox IsChecked="{Binding BoolProperty, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type src:Window1}}}" Content="BoolProperty"/&gt;
          &lt;ContentControl Content="{Binding BoolProperty, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type src:Window1}}}"&gt;
              &lt;ContentControl.ContentTemplate&gt;
                  &lt;DataTemplate&gt;
                      &lt;CheckBox IsChecked="{Binding BoolProperty, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type src:Window1}}}" Content="Template 1"/&gt;
                  &lt;/DataTemplate&gt;
              &lt;/ContentControl.ContentTemplate&gt;
              &lt;ContentControl.Resources&gt;
                  &lt;DataTemplate x:Key="Template2"&gt;
                      &lt;CheckBox IsChecked="{Binding BoolProperty, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type src:Window1}}}" Content="Template 2"/&gt;
                  &lt;/DataTemplate&gt;
              &lt;/ContentControl.Resources&gt;
              &lt;ContentControl.Style&gt;
                  &lt;Style TargetType="ContentControl"&gt;
                      &lt;Style.Triggers&gt;
                          &lt;DataTrigger Binding="{Binding BoolProperty, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type src:Window1}}}" Value="True"&gt;
                              &lt;Setter Property="ContentTemplate" Value="{StaticResource Template2}"/&gt;
                          &lt;/DataTrigger&gt;
                      &lt;/Style.Triggers&gt;
                  &lt;/Style&gt;
              &lt;/ContentControl.Style&gt;
          &lt;/ContentControl&gt;
          &lt;Button Name="btnSwitch" Content="Switch"/&gt;
      &lt;/StackPanel&gt;
  &lt;/Window&gt;
  </code></pre>
  
  <hr>
  
  <pre class="lang-vb prettyprint-override"><code>Partial Class Window1
      Public Property BoolProperty() As Boolean
          Get
              Return GetValue(BoolPropertyProperty)
          End Get
          Set(ByVal value As Boolean)
              SetValue(BoolPropertyProperty, value)
          End Set
      End Property
      Public Shared ReadOnly BoolPropertyProperty As DependencyProperty = DependencyProperty.Register("BoolProperty", GetType(Boolean), GetType(Window1), New FrameworkPropertyMetadata(False))
  
      Private Sub btnSwitch_Click(ByVal sender As System.Object, ByVal e As System.Windows.RoutedEventArgs) Handles btnSwitch.Click
          BoolProperty = Not BoolProperty
      End Sub
  End Class
  </code></pre>