public void InsertEmpWorkTable(int task, int emp, DateTime date, decimal hours) { ProjectTrackingDataSetTableAdapters.EmployeeWorkTableAdapter myAdapter = GetEmpWorkAdapter(); myAdapter.Insert(task, emp, date, hours); myDataSet.EmployeeWork.AcceptChanges(); myAdapter.Update(myDataSet.EmployeeWork); }
public void DeleteEmpWorkRow(int task, int emp, DateTime work) { ProjectTrackingDataSetTableAdapters.EmployeeWorkTableAdapter myAdapter = GetEmpWorkAdapter(); myAdapter.Delete(task, emp, work.ToShortDateString()); myDataSet.EmployeeWork.AcceptChanges(); myAdapter.Update(myDataSet.EmployeeWork); }
public void UpdateEmpWorkRow(int rowIndex, int task, int emp, DateTime date, decimal hours) { ProjectTrackingDataSetTableAdapters.EmployeeWorkTableAdapter myAdapter = GetEmpWorkAdapter(); myDataSet.EmployeeWork[rowIndex][1] = emp; myDataSet.EmployeeWork[rowIndex][2] = date; myDataSet.EmployeeWork[rowIndex][3] = hours; myAdapter.Update(myDataSet.EmployeeWork); }