private void LogoutButton_Click(object sender, EventArgs e) { handler = null; loggedIn = false; PassTextB.Text = null; UnHideLoginComp(); HideMainComp(); }
private void LoginButton_Click(object sender, EventArgs e) { try { handler = new MailHandler(); handler.LoginUser(EmailTextB.Text, PassTextB.Text); LoggedEmailInf.Text = handler.User.Email; HideLoginComp(); UnHideMainComp(); } catch (Exception ex) { MessageBox.Show(ex.Message + " " + ex.StackTrace); } }