//TO REGISTER THE USER public void InputUser() { //To find to the user _objUserBL = new UserBL(); var userList = _objUserBL.GetAllOrASingleUser(cod_usuario: _codUser); //To check if the user exists if (userList.Count > 0) { _pert01Usuario = userList[0]; lblNameUser.Text = _pert01Usuario.txt_usuario; txtCodUser.Text = ""; FrmClockInOut frmClockInOut = new FrmClockInOut { _pert01Usuario = _pert01Usuario }; frmClockInOut.Show(); } else { //To show info message msg = new Msg(); msg.Ok_Info("Su código es incorrecto. Vuelva a intentarlo. "); } }
public void Output() { if (_pert01Usuario.txt_clave == txtCodUser.Text) { FrmClockInOut frmClockInOut = new FrmClockInOut { _stateInputOutput = true, _pert01Usuario = _pert01Usuario }; frmClockInOut.Show(); } else { //To show info message msg = new Msg(); msg.Ok_Info("Su clave es incorrecta. Vuelva a intentarlo. "); //throw; } }