Exemple #1
0
        private void btnIniciarSesion_Click(object sender, EventArgs e)
        {
            if (cmbUsuario.SelectedValue.Equals(txtPassword.Text))
            {
                u = (Usuario)cmbUsuario.SelectedItem;

                MessageBox.Show("¡Bienvenido!",
                                "HUGO", MessageBoxButtons.OK, MessageBoxIcon.Information);

                fmrPrincipal ventana = new fmrPrincipal(u);
                ventana.Show();
                this.Hide();
            }
            else
            {
                MessageBox.Show("¡Contraseña incorrecta!", "Hugo",
                                MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
            }
        }
Exemple #2
0
        private void btnUsuarios_Click(object sender, EventArgs e)
        {
            fmrPrincipal ventana = new fmrPrincipal(pUsuario);

            ventana.Show();
        }