Example #1
0
        protected async void ActionSearch()
        {
            String    email      = Convert.ToString(_valeurEmail);
            WSService connection = WSService.GetInstance();

            try
            {
                var result = await connection.GetCompteByEmailAsync("Comptes/GetCompteByEmail/" + email);

                if (result.Nom == null)
                {
                    this.MessageBox("Aucun compte correspondant n'a été trouvé");
                }
                else
                {
                    this.ValeurCompteNom = result.Nom;
                }
            }
            catch (HttpRequestException e)
            {
                this.MessageBox("La connexion à la base de donnée à échoué");
            }
        }