title: CollectionViewSource "Value does not fall within the expected range."
body: <p>Why does this code produce the error in a Windows 8 XAML application?</p>
  
  <blockquote>
    <p>Value does not fall within the expected range.</p>
  </blockquote>
  
  <p>The XAML:</p>
  
  <pre><code>    &lt;SemanticZoom&gt;
          &lt;SemanticZoom.ZoomedInView&gt;
              &lt;ListView
                  Style="{StaticResource HorizontalListViewStyle}"
                  SelectionMode="None"
                  ScrollViewer.IsHorizontalScrollChainingEnabled="False"
                  ItemsSource="{Binding BoardItems}" 
                  ItemContainerStyle="{StaticResource ZoomedOutListViewItemContainerStyle}"
  ...
  </code></pre>
  
  <p>The MVVM code:</p>
  
  <pre><code>ObservableCollection&lt;WritingBoardModel&gt; boards = new ObservableCollection&lt;WritingBoardModel&gt;();
  
  ... // Add item models to boards.
  
  CollectionViewSource v = new CollectionViewSource()
  {
      Source = boards,
  };
  
  this.ViewModel.Add(BoardItemsViewModelKey, v);
  </code></pre>
  
  <p>If I skip the <code>CollectionViewSource</code> and directly add the <code>boards</code> instance to my view model, then it all works.</p>
  
  <p>I think I need to use a <code>CollectionViewSource</code> in order to get some semantic zoom selection behaviour to work.</p>