Пример #1
0
        public async void ConfirmToken(string theSenttoken)
        {
            try
            {
                EmailTokenDataPayLoad tokenDetail = new EmailTokenDataPayLoad
                {
                    email     = email,
                    ipAddress = ipAddress,
                    sentToken = theSenttoken
                };

                ResponseMessage response = await service.ConfirmTokenControllerService(tokenDetail);

                if (response.ResponseStatusCode == System.Net.HttpStatusCode.NotFound)
                {
                    MessageDialog md = new MessageDialog("Token Does Not Exist or Expired", "Invalid Token");
                    await md.ShowAsync();
                }
                else if (response.ResponseStatusCode == System.Net.HttpStatusCode.Found)
                {
                    //txtEmail.Text = "";
                    hideStackPanels();
                    stackNewPassword.Visibility = Visibility.Visible;
                    MessageDialog md = new MessageDialog("Enter new Password", "Confirmed!");
                    await md.ShowAsync();
                }
            }
            catch (Exception ex)
            {
                checkInternet();
            }
        }