Exemple #1
0
        private void dataGridView1_CellContentClick(object sender, DataGridViewCellEventArgs e)
        {
            string colName = dataGridView1.Columns[e.ColumnIndex].Name;


            if (colName == "colCancel")
            {
                CancelOrderDetails cancle = new CancelOrderDetails(this);
                cancle.txt_ID.Text          = dataGridView1.Rows[e.RowIndex].Cells[1].Value.ToString();
                cancle.txt_Transno.Text     = dataGridView1.Rows[e.RowIndex].Cells[2].Value.ToString();
                cancle.txtprocode.Text      = dataGridView1.Rows[e.RowIndex].Cells[3].Value.ToString();
                cancle.txt_description.Text = dataGridView1.Rows[e.RowIndex].Cells[4].Value.ToString();
                cancle.txtPrice.Text        = dataGridView1.Rows[e.RowIndex].Cells[5].Value.ToString();
                cancle.textBox1.Text        = dataGridView1.Rows[e.RowIndex].Cells[6].Value.ToString();
                cancle.txtDisc.Text         = dataGridView1.Rows[e.RowIndex].Cells[7].Value.ToString();
                cancle.txtTotal.Text        = dataGridView1.Rows[e.RowIndex].Cells[8].Value.ToString();
                cancle.txtCancelledvy.Text  = suser;



                cancle.Show();
            }
        }
Exemple #2
0
 public Void(CancelOrderDetails cn)
 {
     InitializeComponent();
     conn = new SqlConnection(db.Myconnection());
     can  = cn;
 }