title: ListBox doesn't refresh after I delete an item
body: <p>This is my class:</p>
  
  <pre><code> [Table]
  public class ListData : INotifyPropertyChanged, INotifyPropertyChanging
  {
      private int _id;
      [Column(IsPrimaryKey = true, IsDbGenerated = true, DbType = "INT NOT NULL Identity", CanBeNull = false, AutoSync = AutoSync.OnInsert)]
      public int Id
      {
          get
          {
              return _id;
          }
          set
          {
              if (_id != value)
              {
                  OnPropertyChanging("Id");
                  _id = value;
                  OnPropertyChanged("Id");
              }
          }
      }
  
      private string _name;
      [Column()]
      public string Name
      {
          get
          { return _name; }
          set
          {
              if (_name != value)
              {
                  OnPropertyChanging("Name");
                  _name = value;
                  OnPropertyChanged("Name");
              }
          }
      }
      private string _url;
      [Column()]
      public string Url
      {
          get
          {
              return _url;
          }
          set
          {
              if (_url != value)
              {
                  OnPropertyChanging("Url");
                  _url = value;
                  OnPropertyChanged("Url");
              }
          }
      }
  
      public event PropertyChangingEventHandler PropertyChanging;
      public event PropertyChangedEventHandler PropertyChanged;
  
      private void OnPropertyChanged(string propertyName)
      {
          if (PropertyChanging != null)
          {
              PropertyChanging(this, new PropertyChangingEventArgs(propertyName));
          }
      }
      private void OnPropertyChanging(string propertyName)
      {
          if (PropertyChanging != null)
          {
              PropertyChanging(this, new PropertyChangingEventArgs(propertyName));
          }
      }
  }
  
  public class ListDataContext : DataContext
  {
      public static string DBConnectionString = "Data Source=isostore:/ListDataDB.sdf";
      public ListDataContext(string sConnectionString)
          : base(sConnectionString)
      { }
      public Table&lt;ListData&gt; Datas;
  }
  </code></pre>
  
  <p>this is part of my xaml (listbox):</p>
  
  <pre><code>&lt;ListBox x:Name="listData" Grid.Row="1"&gt;
              &lt;ListBox.ItemTemplate&gt;
                  &lt;DataTemplate&gt;
                      &lt;StackPanel  Orientation="Horizontal" VerticalAlignment="Center"&gt;
                          &lt;TextBlock Text="{Binding Path=Name}" 
                                                     Style="{StaticResource PhoneTextTitle2Style}"
                                                     x:Name="txbName"
                                                     Tap="txbName_Tap"&gt;
                          &lt;/TextBlock&gt;
  
                          &lt;Button Tag="{Binding BindsDirectlyToSource=True}" 
                                              Click="Button_Click"  
                                              Content="X" 
                                              BorderBrush="Red" 
                                              Background="Red" 
                                              Foreground="{StaticResource PhoneBackgroundBrush}" 
                                              VerticalAlignment="Top" BorderThickness="0" Width="70" Height="70"&gt;
                          &lt;/Button&gt;
                      &lt;/StackPanel&gt;
                  &lt;/DataTemplate&gt;
              &lt;/ListBox.ItemTemplate&gt;
          &lt;/ListBox&gt;
  </code></pre>
  
  <p>here is my methods for loading data:</p>
  
  <pre><code>public void LoadData()
      {
          this.listData.ItemsSource = GetData();
      }
  
      public ObservableCollection&lt;ListData&gt; GetData()
      {
          List&lt;ListData&gt; listDatas = new List&lt;ListData&gt;();
          using (var db = new ListDataContext(ConnectionString))
          {
              var query = from e in db.Datas
                          select e;
              listDatas = query.ToList();
          }
  
          return new ObservableCollection&lt;ListData&gt;(listDatas);
      }
  </code></pre>
  
  <p>and this is how I delete them:</p>
  
  <pre><code>private void Button_Click(object sender, RoutedEventArgs e)
          {
              try
              {
                  var data = (ListData)((Button)sender).Tag;
                  using (var db = new ListDataContext(ConnectionString))
                  {
                      var entities = from i in db.Datas
                                   where i.Name == data.Name
                                   select i;
                      var entity = entities.FirstOrDefault();
                      db.Datas.DeleteOnSubmit(entity);
                      db.SubmitChanges();
                  }
              }
              catch (Exception ex)
              {
                  MessageBox.Show(ex.Message);
              }
          }
  </code></pre>
  
  <p>What´s the problem? Why isn't my ListBox refreshing after deleting? Is there some problem with ObservableCollection? </p>