title: Binding to a static property in WinRT
body: <p>I believe this is possible, but I don't seem to be able to get it to work;  here's my view model:</p>
  
  <pre><code>namespace MyApp.ViewModel
  {
      public class MainViewModel : INotifyPropertyChanged
      {
          private static MainViewModel _mvm;
          public static MainViewModel MVM()
          {
              if (_mvm == null)
                  _mvm = new MainViewModel();
  
              return _mvm;
          }
  
          private string _imagePath = @"c:\location\image.png";
          public string ImagePath
          {
              get { return _imagePath; }
              set
              {
                 SetProperty&lt;string&gt;(ref _imagePath, value); 
              }
          }
  
          public event PropertyChangedEventHandler PropertyChanged;
  
          protected bool SetProperty&lt;T&gt;(ref T storage, T value, [CallerMemberName] String propertyName = null)
          {
              if (Equals(storage, value)) return false;
  
              storage = value;
              OnPropertyChanged&lt;T&gt;(propertyName);
              return true;
          }
  
          private void OnPropertyChanged&lt;T&gt;([CallerMemberName]string caller = null)
          {
              var handler = PropertyChanged;
              if (handler != null)
              {
                  handler(this, new PropertyChangedEventArgs(caller));
              }
          }
   ...
  </code></pre>
  
  <p>Here's my App.xaml:</p>
  
  <pre><code>xmlns:vm="using:MyApp.ViewModel"&gt;
  
  &lt;Application.Resources&gt;
      &lt;ResourceDictionary&gt;
          &lt;vm:MainViewModel x:Key="MainViewModel"  /&gt;
      &lt;/ResourceDictionary&gt;
  &lt;/Application.Resources&gt;
  </code></pre>
  
  <p>Here's the binding:</p>
  
  <pre><code>&lt;Page
   ...
      DataContext="{Binding MVM, Source={StaticResource MainViewModel}}"&gt;
  
      &lt;StackPanel Orientation="Horizontal" Margin="20" Grid.Row="0"&gt;
          &lt;TextBlock FontSize="30" Margin="10"&gt;Image&lt;/TextBlock&gt;            
          &lt;TextBox Text="{Binding ImagePath}" Margin="10"/&gt;
      &lt;/StackPanel&gt;
  ...
  </code></pre>
  
  <p>I don't seem to be able to get the binding to work; what have I missed here?  I would expect the field to be populated with the default value, but it isn't; I've put breakpoints in the ViewModel, but it is not breaking.</p>