Ejemplo n.º 1
0
        public void addrental()
        {
            eRental rental = new eRental();

            rental.CustomerID = Convert.ToInt32(cmbCustomerID.Text);
            rental.RentalDate = Convert.ToDateTime(dtpRental.Text);

            rentalbll.insertRental(rental);



            //LoadDataGridView(dgvRental, rentalbll.getAllRental());

            LoadDataGridView(dgvRental, rentalbll.getRentalByCustomerID(Convert.ToInt32(cmbCustomerID.Text)));

            eRental ren1 = new eRental();

            ren1.RentalID = rentalbll.maxRentalID();

            frmDiskRental child = new frmDiskRental();

            child.Rentalid = Convert.ToInt32(rentalbll.maxRentalID().ToString());
            child.Status   = true;
            child.Show();
        }
Ejemplo n.º 2
0
        private void btnCheck_Click(object sender, EventArgs e)
        {
            if (checkInput1() == true)
            {
                eRental rental = new eRental();

                rental.CustomerID = Convert.ToInt32(cmbCustomerID.Text);
                rental.RentalDate = Convert.ToDateTime(dtpRental.Text);

                frmDiskRental child = new frmDiskRental();
                child.Rentalid = Convert.ToInt32(lblRentalID.Text);
                child.Status   = false;
                child.Show();
            }
        }