title: Observable collection collection changed question
body: <p>I am learning about observable collections, so I wrote a small program to test my progress.
  I have a observable collection class that I supply initial values from a list and bind the observablecollection to a Datagrid. It works great, but when I clear the list using myListOfPlayers.myList.Clear(), the Datagrid does not clear. I thought that the INotifyPropertyChanged property would handle that. What am I doing wrong?</p>
  
  <pre><code>public class PlayerList : ObservableCollection&lt;PlayerName&gt; //observable collection class
      {
          public PlayerList()
              : base()
          {
              Clear();
  
              foreach (var p in myListOfPlayers.myList.OrderBy(x =&gt; x.Score))
              {
                  Add(p);
              }
          }
  
          public PlayerList(List&lt;PlayerName&gt; list)
              : base(list)
          {
              Clear();
  
              foreach (var p in list)
              {
                  Add(p);
              }
          }
      }
  </code></pre>
  
  <p>I implement INotifyPropertyChanged in the PlayerName class:</p>
  
  <pre><code>public class PlayerName : INotifyPropertyChanged
      {
          private string _name;
  
          public string Name
          {
              get { return _name; }
              set
              {
                  _name = value;
                  OnPropertyChanged("Name");
              }
          }
  
          private int _score;
  
          public int Score
          {
              get { return _score; }
              set
              {
                  _score = value;
                  OnPropertyChanged("Score");
              }
          }
  
          public event PropertyChangedEventHandler PropertyChanged;
  
          protected virtual void OnPropertyChanged(string propertyName)
          {
              var handler = PropertyChanged;
  
              if (handler != null)
              {
                  handler(this, new PropertyChangedEventArgs(propertyName));
              }
          }
      }
  </code></pre>