private void BtnDangNhap_Click(object sender, EventArgs e) { if (IsCorrectAccount(txbUser.Text, txbPassword.Text)) { fMain f = new fMain(txbUser.Text); int IDShift = getIDShiftFromUser(txbUser.Text); while (IDShift == -1) { ShiftDAO.Instance.insertShift(txbUser.Text); IDShift = getIDShiftFromUser(txbUser.Text); } f.idShift = IDShift; Hide(); f.parent = this; f.Show(); } else { MessageBox.Show("Sai tên tài khoản hoặc mật khẩu.", "Thông báo", MessageBoxButtons.OK); } }
private void fAddNewBill_FormClosed(object sender, FormClosedEventArgs e) { parentForm.Show(); }
private void fFoodManager_FormClosed(object sender, FormClosedEventArgs e) { parentForm.Show(); }