private void btnSeeUser_Click(object sender, EventArgs e) { FormUser formUser = new FormUser(); formUser.Show(); Close(); // formUser.labelLoginCount.Text }
private void btnEnter_Click(object sender, EventArgs e) { if (login == null) { DialogResult result = MessageBox.Show( "pls enter login", "Сообщение", MessageBoxButtons.OK, MessageBoxIcon.Warning, MessageBoxDefaultButton.Button1, MessageBoxOptions.DefaultDesktopOnly); if (result == DialogResult.OK) { textBoxLogin.BackColor = Color.Red; } Console.WriteLine("pls enter login"); } else if (login != null && password == null) { MessageBox.Show("Please enter password"); Console.WriteLine("pls enter paswrd"); } else if (login != null && password != null) { if (Connection.login(login, password)) { currentUser = Connection.getFullDB(login); Console.WriteLine("login:"******" " + "password:"******"Upps..."); Console.WriteLine("Upps..."); } } }