/// <summary> /// Update the database using table adapters update and fill methods /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void ButtonUpdate_Click(object sender, EventArgs e) { inventoryTableAdapter.Update(inventoryTable); customersTableAdapter.Update(customersTable); ordersTableAdapter.Update(ordersTable); inventoryTableAdapter.Fill(inventoryTable); customersTableAdapter.Fill(customersTable); ordersTableAdapter.Fill(ordersTable); }
private void btnUpdate_Click(object sender, EventArgs e) { try { invTableAdapter.Update(autoLotDS.Inventory); custTableAdapter.Update(autoLotDS.Customers); ordersTableAdapter.Update(autoLotDS.Orders); } catch (Exception ex) { MessageBox.Show(ex.Message); } }