private void buttonUpdateBook_Click(object sender, EventArgs e)
        {
            List <Inventory> listI = InventoryDA.ListInventory();

            if (IsValidInventoryData())
            {
                Inventory aProducts = new Inventory();
                aProducts.ISBNProduct          = Convert.ToInt32(textBoxISBN.Text);
                aProducts.ProductTitle         = textBoxBookTitle.Text;
                aProducts.ProductDescription   = comboboxProductDescription.Text;
                aProducts.AuthorID             = Convert.ToInt32(comboBoxAuthorId.Text);
                aProducts.PublisherName        = comboBoxPublisherName.Text;
                aProducts.ProductYearPublished = Convert.ToInt32(textBoxYearPushlished.Text);
                aProducts.ProductQuantity      = Convert.ToInt32(textBoxQuantityOnHand.Text);
                aProducts.ProductPrice         = Convert.ToDouble(textBoxBookPrice.Text);
                DialogResult ans = MessageBox.Show("Do you really want to update this Books?", "Confirmation", MessageBoxButtons.YesNo, MessageBoxIcon.Information);
                if (ans == DialogResult.Yes)
                {
                    InventoryDA.Update(aProducts);
                    MessageBox.Show("Product record has been updated successfully", "Confirmation");
                    ClearAll();
                    textBoxISBN.Enabled = true;
                }
            }
        }
 public bool Update(int id, int stocklevel, int locID)
 {
     return(invenDa.Update(id, stocklevel, locID));
 }