W
walt
Why won't this code add a row to my database? It runs as expected but
when I look in the SQL database using SQL Server Management Studio the
table is empty.
DataRow newRow =
this.dsHealthClub.NotInHouse.NewRow();
newRow["Name"] =
dsEmployees.Employees.Rows[0].ItemArray.GetValue(0);
newRow["DateOut"] = DateTime.Now;
newRow["Comments"] = "";
newRow["Badge"] = visitorID;
this.dsHealthClub.NotInHouse.Rows.Add(newRow);
when I look in the SQL database using SQL Server Management Studio the
table is empty.
DataRow newRow =
this.dsHealthClub.NotInHouse.NewRow();
newRow["Name"] =
dsEmployees.Employees.Rows[0].ItemArray.GetValue(0);
newRow["DateOut"] = DateTime.Now;
newRow["Comments"] = "";
newRow["Badge"] = visitorID;
this.dsHealthClub.NotInHouse.Rows.Add(newRow);