private void LoginButton_Click(object sender, EventArgs e) { controller = new AccountBLL(); if (controller.Login(tbUsername.Text, tbPassword.Text)) { MessageBox.Show("Login thanh cong"); LoginForm.getInstance().Hide(); MainUI main = new MainUI(tbUsername.Text); main.Show(); //MainUIWPF main = new MainUIWPF(); //main. } else { MessageBox.Show("That bai"); } }
static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); Application.Run(LoginForm.getInstance()); }
//logout private void button1_Click(object sender, EventArgs e) { this.Dispose(); LoginForm.getInstance().Show(); }