private void button1_Click(object sender, EventArgs e) { frm_product_entry frm = new frm_product_entry(); frm.StartPosition = FormStartPosition.CenterScreen; frm.ShowDialog(); DisplayProductAsync(); }
private void cToolStripMenuItem_Click(object sender, EventArgs e) { int ProductID = Convert.ToInt16(dataGridView1.Rows[SelectedRow].Cells[0].Value); Product p = Product.GetProduct(products, ProductID); frm_product_entry frm = new frm_product_entry(p); frm.StartPosition = FormStartPosition.CenterScreen; frm.ShowDialog(); DisplayProductAsync(); }