private void dataGridView1_CellContentClick(object sender, DataGridViewCellEventArgs e) { if (e.ColumnIndex == 5) { LoadQuantity loadQuantity = new LoadQuantity(); // this.AllowTransparency=true; // this.panel3.Visible = true; // panel3.BackColor = Color.FromArgb(125, Color.Black); loadQuantity.Show(); } else if (e.ColumnIndex == 7) { EditMedicine editMedicine = new EditMedicine(); editMedicine.Show(); } else if (e.ColumnIndex == 8) { DialogResult confirm = MessageBox.Show("Are you sure you want to delete this medicine", "Delete Medicine", MessageBoxButtons.OKCancel, MessageBoxIcon.Question); if (confirm == DialogResult.OK) { MessageBox.Show("so deletion confirm"); } } }
private void StockOutDataGridView_CellContentClick(object sender, DataGridViewCellEventArgs e) { if (e.ColumnIndex == 5) { LoadQuantity loadQuantity = new LoadQuantity(); loadQuantity.Show(); } else if (e.ColumnIndex == 7) { EditMedicine editMedicine = new EditMedicine(); editMedicine.Show(); } else if (e.ColumnIndex == 8) { DialogResult confirm = MessageBox.Show("Are you sure you want to delete this medicine", "Delete Medicine", MessageBoxButtons.OKCancel, MessageBoxIcon.Question); if (confirm == DialogResult.OK) { MessageBox.Show("so deletion confirm"); } } }