private void button2_Click(object sender, EventArgs e) { F_AddProduct f_ = new F_AddProduct(); f_.txtID.Text = dataGridView1.CurrentRow.Cells[0].Value.ToString(); f_.txtDes.Text = dataGridView1.CurrentRow.Cells[1].Value.ToString(); f_.txtQun.Text = dataGridView1.CurrentRow.Cells[2].Value.ToString(); f_.txtPrice.Text = dataGridView1.CurrentRow.Cells[3].Value.ToString(); f_.comboBox1.Text = dataGridView1.CurrentRow.Cells[4].Value.ToString(); f_.Text = "Update Prodect" + dataGridView1.CurrentRow.Cells[1].Value.ToString(); f_.state = "update"; byte[] image = (byte[])prd.getimage(dataGridView1.CurrentRow.Cells[0].Value.ToString()).Rows[0][0]; MemoryStream ms = new MemoryStream(image); f_.pictureBox1.Image = Image.FromStream(ms); f_.ShowDialog(); }
private void addProductToolStripMenuItem_Click(object sender, EventArgs e) { F_AddProduct f_Add = new F_AddProduct(); f_Add.ShowDialog(); }
private void btnOK_Click(object sender, EventArgs e) { F_AddProduct f_ = new F_AddProduct(); f_.ShowDialog(); }