/// <summary> /// Login Operation /// </summary> /// <returns></returns> public ResultSet LoginOperation() { bool tryAgain = true; ResultSet result = null; while (tryAgain) { Console.WriteLine("Please Enter Username:"******"Please Enter Password:"); var password = Console.ReadLine(); User user = new User(userName, password); try { //Save User To Json DB result = _dbQuery.Login(user); } catch (Exception ex) { Log.Error(ex.Message); } if (result.Status != Status.Success) { if (GeneralHelper.CheckIfType <string>(result.ReturnResult)) { Console.WriteLine(result.ReturnResult.ToString()); } } else { tryAgain = false; } } return(result); }