title: Filtering an ObservableCollection by using an IValueConverter
body: <p>I'm building a Windows 8 Metro Application where I need to filter an <code>ObservableCollection</code>. Sadly, the CollectionViewSource-Class in the WinRT-Framework doesn't support filtering so I try to use an <code>IValueConverter</code> for doing so.</p>
  
  <p>My XAML:</p>
  
  <pre><code>&lt;RadioButton Content="this Week" GroupName="AppointmentFilter" IsChecked="True" Name="rbtnFilter"/&gt;
  &lt;RadioButton Content="all" GroupName="AppointmentFilter"/&gt;
  &lt;ListView ItemsSource="{Binding Appointments, ConverterParameter={Binding rbtnFilter.IsChecked}, Converter={StaticResource Filter}}"/&gt;
  </code></pre>
  
  <p>My IValueConverter:</p>
  
  <pre><code>public class AppointmentListFilter : IValueConverter
  {
      public object Convert(object value, Type targetType, object parameter, string language)
      {
          ObservableCollection&lt;VMAppointment&gt; appointments = value as ObservableCollection&lt;VMAppointment&gt;;
          bool filter = (bool)parameter;
  
          if (filter)
          {
              return new ObservableCollection&lt;VMAppointment&gt;(appointments.Where(x =&gt; x.Date.CompareTo(DateTime.Now.AddDays(7)) &lt;= 0));
          }
          else
          {
              return appointments;
          }
      }
  
      public object ConvertBack(object value, Type targetType, object parameter, string language)
      {
          throw new NotImplementedException();
      }
  }
  </code></pre>
  
  <p>When the <code>IValueConverter</code> is being executed, the parameter "parameter" is null and not a boolean value. What am I doing wrong?</p>