private void BtnLogin_Click(object sender, EventArgs e) { try { Usuarios us = new Usuarios( TxtLogin.Text , TxtPassword.Text ); if ( us.Existe ) { new Parser( ).InitValues( us.Privilegios ); Hide( ); Thread thread = new Thread( new ThreadStart( Splash ) ); thread.Start( ); Thread.Sleep( 6000 ); thread.Abort( ); Injector.Link main = new Injector.Link( us ); ConexionBD.UsuarioActual = us; } else { MessageBox.Show( "El Login y/o el Password son incorrectos" , "Atención" , MessageBoxButtons.OK , MessageBoxIcon.Information ); } } catch ( Exception ex) { log.Error( ex.Message , ex ); alertControl.Show( this , "Hubo un error" , ex.Message , Image ); MessageBox.Show( ex.Message ); } }
private void BtnLogin_Click(object sender, EventArgs e) { try { Usuarios us = new Usuarios(TxtLogin.Text, TxtPassword.Text); if (us.Existe) { new Parser( ).InitValues(us.Privilegios); Hide( ); Thread thread = new Thread(new ThreadStart(Splash)); thread.Start( ); Thread.Sleep(6000); thread.Abort( ); Injector.Link main = new Injector.Link(us); ConexionBD.UsuarioActual = us; } else { MessageBox.Show("El Login y/o el Password son incorrectos", "Atención", MessageBoxButtons.OK, MessageBoxIcon.Information); } } catch (Exception ex) { log.Error(ex.Message, ex); alertControl.Show(this, "Hubo un error", ex.Message, Image); MessageBox.Show(ex.Message); } }