示例#1
0
        private void Fill()
        {
            Product product = new Product();

            product.Name     = dataGridView1.SelectedRows[0].Cells[1].Value.ToString();
            product.Quantity = int.Parse(dataGridView1.SelectedRows[0].Cells[2].Value.ToString());
            product.Price    = float.Parse(dataGridView1.SelectedRows[0].Cells[3].Value.ToString());

            FormProductData frm = new FormProductData();

            frm.FillForm(product.Name, product.Price, product.Quantity);
            frm.Show();
        }
示例#2
0
        private void btnNew_Click(object sender, EventArgs e)
        {
            FormProductData frm = new FormProductData();

            frm.Show();
        }