title: How do you bind an observable collection to a listview located in a modal/window?
body: <p>I have a wpf application that I want to be able to launch a separate window in which I will have a listview bound to an observable collection. However I am unable to get the collection values to appear in the list view. Here is some of the code.</p>
  <p>Window (Named WizardView):</p>
  <p>(Data context defined like so at top of xaml):
  d:DataContext=&quot;{d:DesignInstance Type=viewModels:MainViewModel}&quot;</p>
  <pre><code>    &lt;Border Grid.Row=&quot;0&quot; Grid.Column=&quot;0&quot; Grid.RowSpan=&quot;3&quot; BorderBrush=&quot;Black&quot;&gt;
          &lt;ListView BorderThickness=&quot;0&quot; ItemsSource=&quot;{Binding TestModel.FailedTests}&quot;&gt;
              &lt;Label Content=&quot;Introduction&quot; FontWeight=&quot;Bold&quot; /&gt;
              &lt;ListView.ItemTemplate&gt;
                  &lt;DataTemplate&gt;
                      &lt;StackPanel&gt;
                          &lt;Label Content=&quot;{Binding }&quot;/&gt;
                      &lt;/StackPanel&gt;
                  &lt;/DataTemplate&gt;
              &lt;/ListView.ItemTemplate&gt;
          &lt;/ListView&gt;
      &lt;/Border&gt;
  </code></pre>
  <p>MainViewModel Code:</p>
  <pre><code>public class MainViewModel : BaseViewModel
  {
      public MainViewModel()
      {
          TestModel = new TestViewModel();
          WizardModel = new WizardViewModel(TestModel);
      }
  
  
      private WizardViewModel _wizardModel;
      public WizardViewModel WizardModel
      {
          get
          {
              return _wizardModel;
          }
          set
          {
              _wizardModel = value;
              RaisePropertyChanged();
          }
      }
  
      private TestViewModel _testViewModel;
      public TestViewModel TestModel
      {
          get
          {
              return _testViewModel;
          }
          set
          {
              _testViewModel = value;
              RaisePropertyChanged();
          }
      }
  </code></pre>
  <p>WizardViewModel Code:</p>
  <pre><code>public class WizardViewModel : TestViewModel
  {
      internal TestViewModel TestModel;
      public WizardViewModel(TestViewModel testModel)
      {
          TestModel = testModel;
  
          (TroubleShootCommand is defined in seperate UC, and launches fine)
          TestModel.TroubleShootCommand = new DelegateCommand(Load, CanTroubleShoot);
      }
  
      public void Load()
      {
       (Sync Root is used because it is running on worker thread. Issue somewhere here?)
          _syncRoot.Send(o =&gt;
          {
              var troubleShootWizard = new WizardView();
              troubleShootWizard.Owner = Application.Current.MainWindow;
              troubleShootWizard.ShowDialog();
          }, null);
      }
  </code></pre>
  <p>Observable Collection in TestViewModel (Initialized in ctor):</p>
  <pre><code>    private ObservableCollection&lt;string&gt; _failedTests;
      public ObservableCollection&lt;string&gt; FailedTests
      {
          get { return _failedTests; }
          set
          {
              _failedTests = value;
              RaisePropertyChanged();
          }
      }
  </code></pre>
  <p>Any Help is appreciated, I feel like I have tried everything. I have watched values through the watch window under TestModel.FailedTests in the collection right before and right after launch.</p>