コード例 #1
0
        private void btnSearchHalls_Click(object sender, EventArgs e)
        {
            try
            {
                BookingHallsBO aBookingHallsBO = new BookingHallsBO();
                bool IsLunar;
                if (cbbLunarDate.Text == "Dương")
                {
                    IsLunar = false;
                }
                else
                {
                    IsLunar = true;
                }
                aListAvailableHall = aBookingHallsBO.GetListStatusHall(dtpFrom.DateTime, IsLunar).Where(p => p.HallStatus == 0).ToList();
                dgvAvailableHalls.DataSource = aListAvailableHall;

            }
            catch (Exception ex)
            {
                MessageBox.Show("frmTsk_UpdBooking.btnSearchHalls_Click\n" + ex.ToString(), "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
 private void btnSearchHall_Click(object sender, EventArgs e)
 {
     try
     {
         BookingHallsBO aBookingHallsBO = new BookingHallsBO();
         aListAvailableHall = aBookingHallsBO.GetListStatusHall(dtpFrom.DateTime, false).Where(p => p.HallStatus == 0).ToList();
         dgvAvailableHalls.DataSource = aListAvailableHall;
     }
     catch (Exception ex)
     {
         MessageBox.Show("frmTsk_BookingHall_Customer_New.btnSearchHalls_Click\n" + ex.ToString(), "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }