private async void ExecuteRegisterUserCommand(string password)
        {
            try
            {
                var response = await this._dataService.RegisterUser(this.RegisterUsername, password, this.Email);

                if (response.IsSuccessStatusCode)
                {
                    var userStr = await response.Content.ReadAsStringAsync();

                    var user = JsonConvert.DeserializeObject <LoginResponseModel>(userStr);
                    this.credetentialsManager.SetCredetentials(user.Username, password);
                    this._navigationService.Navigate("ItemsPage", user);
                }
            }
            catch (ArgumentException ae)
            {
                ErrorDisplayer.ShowError(ae.Message);
            }
        }
 public int OnAfterOpenSolution(object pUnkReserved, int fNewSolution)
 {
     try
     {
         foreach (var project in allProjectFinder.GetAllProjects())
         {
             try
             {
                 taskFileProcessor.ProcessTaskFile(project);
             }
             catch (Exception exception)
             {
                 errorDisplayer.ShowError(string.Format("Costura: An exception occured while trying to process {0}.\r\nException: {1}.", project.FullName, exception));
             }
         }
     }
     catch (Exception exception)
     {
         exceptionDialog.HandleException(exception);
     }
     return(VSConstants.S_OK);
 }
Beispiel #3
0
 public override void OnJoinRoomFailed(short returnCode, string message)
 {
     base.OnJoinRandomFailed(returnCode, message);
     Loader.Instance.StopLoading();
     errorDisplayer.ShowError(message);
 }