datagrid中的删除问题?
int index=this.dataGrid1.CurrentCell.RowNumber;
this.datasetTxl.Tables["txl"].Rows[index].Delete();
try
{
this.datasetTxl.AcceptChanges();
this.adapTxl.Update(this.datasetTxl,"txl");
}
catch(Exception ex)
{
MessageBox.Show(ex.ToString());
}
为什么在数据库中无法删除这条数据啊??
郁闷中!