title: WP7 - Control Template - unknown exception
body: <p>I'm working through a beginners book to wp7 and in one of the basic tutorials I have been encountering an unknown exception.</p>
  
  <p>The control template defined in the Application resources (App.xaml) file is as below.</p>
  
  <pre><code>&lt;Application.Resources&gt;
      &lt;Style x:Key="CustomButtonStyle" TargetType="Button"&gt;
          &lt;Setter Property="Template"&gt;
              &lt;Setter.Value&gt;
                  &lt;ControlTemplate&gt;
                      &lt;Border Width="{TemplateBinding Width}" Height="{TemplateBinding Height}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}"&gt;
                          &lt;StackPanel&gt;
                              &lt;Image Source="Images\image.png" Width="200" Height="300" /&gt;
                              &lt;TextBlock Text="{TemplateBinding Content}" TextAlignment="Center" /&gt;
                          &lt;/StackPanel&gt;
                      &lt;/Border&gt;
                  &lt;/ControlTemplate&gt;
              &lt;/Setter.Value&gt;
          &lt;/Setter&gt;
      &lt;/Style&gt;
  &lt;/Application.Resources&gt;
  </code></pre>
  
  <p>Then when I create a button that uses this template eg</p>
  
  <pre><code>&lt;Grid x:Name="ContentPanel" Grid.Row="1" Margin="12,0,12,0"&gt;
              &lt;Button x:Name="CustomButton" Width="250" Height="350" Content="Custom Button" Style="{StaticResource CustomButtonStyle}" /&gt;
          &lt;/Grid&gt;
  </code></pre>
  
  <p>I always get a unknown exception raised. I've narrowed it down to the </p>
  
  <pre><code>Text="{TemplateBinding Content}"
  </code></pre>
  
  <p>Attribute in the control template but, why is there an exception? I have the content there, its in a string format. I don't know what else it may be?
  When I create a project I target Windows Phone 7.1. Was there some change I'm unaware of?
  Any help is appreciated.
  Thanks
  Joe</p>