I have a datagridview thats bounded to a db and bindingNavigator that has Add/Delete/Save buttons. When I select a row and delete it, the row gets deleted from the datagridview, but when I restart the application, it doesn't get physically deleted from the database. Search suggests putting this code inside the save button and press it before closing the application:
this.Validate();
this.itemsBindingSource.EndEdit();
this.itemsTableAdapter.Update(this.myDatabaseDataSet.Items);
MessageBox.Show("Update successful");
But the database still have the row undeleted.
And using itemTableAdapter.Delete() method isn't really helpful since I've more than 30 columns in the table.
Any help?.