title: VS2012 The resource "X" could not be resolved
body: <p>I have a Resources.xaml file in my project that contains a resource dictionary like so:</p>
  
  <pre><code>&lt;ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"&gt;
  
      &lt;Style x:Key="GPHeaderFontSize" TargetType="TextBlock"&gt;
          &lt;Setter Property="FontWeight" Value="Bold" /&gt;
          &lt;Setter Property="FontSize" Value="24" /&gt;
          &lt;Setter Property="Text" Value="BLAHHHHH"/&gt;
      &lt;/Style&gt;
  &lt;/ResourceDictionary&gt;
  </code></pre>
  
  <p>I have included this dictionary in App.xaml like so:</p>
  
  <pre><code>&lt;Application x:Class="GoldenPlains.App" 
      xmlns="schemas.microsoft.com/winfx/2006/xaml/presentation"; 
      xmlns:x="schemas.microsoft.com/winfx/2006/xaml"; 
      xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone" 
      xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone"&gt;
      &lt;Application.Resources&gt; 
          &lt;local:LocalizedStrings xmlns:local="clr-namespace:GoldenPlains" x:Key="LocalizedStrings"/&gt; 
          &lt;ResourceDictionary x:Key="GPResources"&gt; 
              &lt;ResourceDictionary.MergedDictionaries&gt; 
                  &lt;!-- Sometimes VS2012 complaining about path with blue line, please ignore it as path is correct --&gt; 
                  &lt;ResourceDictionary Source="Styles/GPResources.xaml"/&gt; 
              &lt;/ResourceDictionary.MergedDictionaries&gt;
              &lt;Style x:Key="GPRootOverlayBarStyle" TargetType="Image"&gt; 
                  &lt;Setter Property="Source" Value="Assets/Images/root_brown_horizontal_bar.png"/&gt; 
                  &lt;Setter Property="Width" Value="729"/&gt; 
                  &lt;Setter Property="HorizontalAlignment" Value="Left"/&gt; 
                  &lt;Setter Property="Stretch" Value="Uniform"/&gt; 
              &lt;/style&gt; 
      &lt;/Application.Resources&gt;
      ...
      ...
  &lt;/Application&gt;
  </code></pre>
  
  <p>However when I try to reference an element in the resource dictionary from another Page.xaml file it cannot seem to resolve the resource.... 
  eg: 
      </p>
  
  <p>I have tried using a binding like so: </p>
  
  <pre><code>&lt;TextBlock Style="{Binding Path=LocalizedResources.MyTextBlockStyle, Source=  {StaticResource GPResources}}"/&gt;
  </code></pre>
  
  <p>it does not indicate that something is wrong but nothing shows up on the UI.</p>
  
  <p>A point in the right direction would be great, cheers.</p>