private void menuAccName_Click(object sender, EventArgs e)
 {
     if (account == null)
     {
         fLogin f = new fLogin();
         f.ShowDialog();
     }
 }
        public fGeneral()
        {
            InitializeComponent();
            this.IsMdiContainer = true;
            this.Show();

            fLogin f = new fLogin();

            fLogin.myevent += updateAccount;
            f.ShowDialog();
        }
Beispiel #3
0
 void PreLoadAllForms()
 {
     frmMain           = this;
     frmLogin          = new fLogin();
     frmAccount        = new fAccount();
     frmAccountInfo    = new fAccountInfo();
     frmChangePassword = new fChangePassword();
     frmFood           = new fFood();
     frmFoodCategory   = new fFoodCategory();
     frmRevenue        = new fRevenue();
     frmTableFood      = new fTableFood();
     frmTableManager   = new fTableManager();
     frmTutorial       = new fTutorial();
     frmSoftwareInfo   = new fSoftwareInfo();
 }
        private void menuLogout_Click(object sender, EventArgs e)
        {
            menuQuanLiChi.Visible = false;
            menuLogout.Visible    = false;
            menuThoat.Visible     = false;
            menuInfo.Visible      = false;

            account          = null;
            menuAccName.Text = "Đăng nhập";

            listForm[listForm.Count - 1].Close();
            listForm.RemoveAt(listForm.Count - 1);
            fLogin f = new fLogin();

            f.ShowDialog();
        }