Exemple #1
0
        private void ByByWindows(object sender, FormClosedEventArgs e)
        {
            Form frm;

            if (sender is Form)
            {
                frm = (Form)sender;
                if (frm == frmLietKeTinhGia)
                {
                    frmLietKeTinhGia = null;
                }
                if (frm == frmBangGiaGiay)
                {
                    frmBangGiaGiay = null;
                }
                if (frm == frmBangGiaThanhPham)
                {
                    frmBangGiaThanhPham = null;
                }
                if (frm == frmBangGiaInNhanh)
                {
                    frmBangGiaInNhanh = null;
                }
                if (frm == frmBangGiaInNhanhMay)
                {
                    frmBangGiaInNhanhMay = null;
                }
                if (frm == frmTinhThu)
                {
                    frmTinhThu = null;
                }
            }
        }
Exemple #2
0
        private void btnBangGiaGiay_Click(object sender, EventArgs e)
        {
            BangGiaGiayForm frm = new BangGiaGiayForm(FormStateS.View);

            frm.MaximizeBox = false;
            frm.MinimizeBox = false;
            frm.Text        = "Bảng giá giấy theo hạng KH ";
            frm.ShowDialog();
        }
Exemple #3
0
 private void btnBangGiaGiay_Click(object sender, EventArgs e)
 {
     if (frmBangGiaGiay == null)
     {
         frmBangGiaGiay             = new BangGiaGiayForm(FormStateS.View);
         frmBangGiaGiay.FormClosed += new FormClosedEventHandler(ByByWindows);
         frmBangGiaGiay.Show();
     }
     else
     {
         frmBangGiaGiay.Focus();
     }
 }
        private void btnLayGiayOffset_Click(object sender, EventArgs e)
        {
            BangGiaGiayForm frm = new BangGiaGiayForm(FormStateS.Get, 0, this.TenGiayDigi);

            frm.MaximizeBox = false;
            frm.MinimizeBox = false;
            frm.Text        = "Bảng giá giấy theo hạng KH ";
            frm.ShowDialog();
            if (frm.DialogResult == System.Windows.Forms.DialogResult.OK)
            {
                //Cập nhật IdGiay trước
                if (frm.GiayChon != null)
                {
                    this.IdGiayOffsetChon = frm.GiayChon.ID;
                    giaInPres.CapNhatChiTietGiayOffset();
                }
                //Cập nhật tiếp các chi tiết
            }
        }