private void btnLogin_Click(object sender, EventArgs e) { if (txtUser.Text == "" || txtPassword.Text == "") { MessageBox.Show("Kode dan Password harus diisi !"); } else { status = Login.Login(txtUser.Text, txtPassword.Text); if (status == false) { MessageBox.Show("Maaf login gagal"); txtUser.Text = ""; txtPassword.Text = ""; txtUser.Focus(); } else { Form2 f2 = new Form2(txtUser.Text); View.Form3 f3 = new View.Form3(txtUser.Text); View.Form4 f4 = new View.Form4(txtUser.Text); f4.Show(); this.Hide(); } } }
private void btnClose_Click(object sender, EventArgs e) { View.Form4 f4 = new View.Form4(user); f4.Show(); this.Hide(); }