Exemple #1
0
        private void dataGridView1_RowHeaderMouseDoubleClick(object sender, DataGridViewCellMouseEventArgs e)
        {
            edit_orders ord = new edit_orders();


            ord.order_id         = Convert.ToInt32(dataGridView1.CurrentRow.Cells[0].Value.ToString().ToString());
            ord.txtitem.Text     = dataGridView1.CurrentRow.Cells[3].Value.ToString();
            ord.txtusers.Text    = dataGridView1.CurrentRow.Cells[1].Value.ToString();
            ord.txtquantity.Text = dataGridView1.CurrentRow.Cells[4].Value.ToString();
            ord.txttableno.Text  = dataGridView1.CurrentRow.Cells[2].Value.ToString();
            ord.cost             = Convert.ToInt32(dataGridView1.CurrentRow.Cells[6].Value.ToString());
            ord.Show();
        }
        private void dataGridView1_RowHeaderMouseDoubleClick(object sender, DataGridViewCellMouseEventArgs e)
        {
            edit_orders ord = new edit_orders();

           
            ord.order_id = Convert.ToInt32(dataGridView1.CurrentRow.Cells[0].Value.ToString().ToString());
            ord.txtitem.Text = dataGridView1.CurrentRow.Cells[3].Value.ToString();
            ord.txtusers.Text = dataGridView1.CurrentRow.Cells[1].Value.ToString();
            ord.txtquantity.Text = dataGridView1.CurrentRow.Cells[4].Value.ToString();
            ord.txttableno.Text = dataGridView1.CurrentRow.Cells[2].Value.ToString();
            ord.cost = Convert.ToInt32(dataGridView1.CurrentRow.Cells[6].Value.ToString());
            ord.Show();
        }