Exemple #1
0
        private void ucBtnExt2_BtnClick(object sender, EventArgs e)
        {
            int         index     = this.dgvtrainInfo.CurrentRow.Index;
            string      trainCode = this.dgvtrainInfo.Rows[index].Cells[0].Value.ToString().Substring(1);
            string      date      = this.dateTimePicker1.Text;
            FrmPurchase purchase  = new FrmPurchase(userName, trainCode, date);

            this.Hide();
            DialogResult dialog = purchase.ShowDialog();

            if (dialog == DialogResult.Cancel)
            {
                this.Show();
            }
        }
Exemple #2
0
        private void button5_Click(object sender, EventArgs e)
        {
            FrmPurchase purchase = new FrmPurchase();

            purchase.Show();
        }