title: C# Error trying to edit item of DataGrid
body: <p>So when i try to edit or add or delete from a DataGrid in WPF is giving me 'EditItem' is not allowed for this view.</p>
  
  <pre><code>providersDataGrid.CanUserAddRows = true;
  providersDataGrid.CanUserDeleteRows = true;
  providersTableAdapter adapter = new providersTableAdapter();
  adapter.Fill(ds.providers);
  providersDataGrid.ItemsSource = adapter.GetData().Rows;
  </code></pre>
  
  <p>i have activated Autogenerate Columns.</p>
  
  <p>So how i can do it? thanks for your answer.</p>