private void showFinalResultScreen(bool isFinish) { var parentForm = (Form)this.Parent; var chiphiString = String.Format("{0} VNĐ", this.totalCharge); var finalScreen = new ExaminationConfirm(this.hoSoBenhAn, this.txtPhong.Text, this.benhNhan, chiphiString, this.listThuoc, this.listXetNghiem, false) { Left = Top = 0, Anchor = AnchorStyles.Left | AnchorStyles.Top }; finalScreen.DidConfirm += (control) => { if (isFinish) { this.showReport(parentForm); } else { parentForm.Close(); reloadRequest?.Invoke(this, null); } }; parentForm.Controls.Clear(); parentForm.Controls.Add(finalScreen); }
private void showConfirm() { var confirmControl = new ExaminationConfirm(this.hoSoBenhAn, this.txtPhong.Text, this.benhNhan, null, this.listThuoc) { Left = Top = 0, Dock = DockStyle.Fill }; confirmControl.DidBack += ConfirmControl_DidBack; confirmControl.DidConfirm += ConfirmControl_DidConfirm; this.Parent?.Controls.Add(confirmControl); confirmControl.BringToFront(); }
private void showConfirm() { var chiphiString = String.Format("{0} VNĐ", this.totalCharge); var confirmControl = new ExaminationConfirm(this.hoSoBenhAn, this.txtPhong.Text, this.benhNhan, chiphiString, this.listThuoc, this.listXetNghiem) { Left = Top = 0, Dock = DockStyle.Fill }; confirmControl.DidBack += ConfirmControl_DidBack; confirmControl.DidConfirm += ConfirmControl_DidConfirm; this.Parent?.Controls.Add(confirmControl); confirmControl.BringToFront(); }
private void showFinalResultScreen() { var parentForm = (Form)this.Parent; var finalScreen = new ExaminationConfirm(this.hoSoBenhAn, this.txtPhong.Text, this.benhNhan, null, this.listThuoc, null, false) { Left = Top = 0, Anchor = AnchorStyles.Left | AnchorStyles.Top }; finalScreen.DidConfirm += (control) => { this.showReport(parentForm); }; parentForm.Controls.Clear(); parentForm.Controls.Add(finalScreen); }