Exemplo n.º 1
0
 private void ValiderRendezVous(CsClient leClient, DateTime laDateRendezVous)
 {
     try
     {
         Galatee.Silverlight.ServiceRecouvrement.RecouvrementServiceClient client = new Galatee.Silverlight.ServiceRecouvrement.RecouvrementServiceClient(Utility.ProtocoleFacturation(), Utility.EndPoint("Recouvrement"));
         client.SaveRDVCoupureHorsCampagneAsync(leClient, laDateRendezVous);
         client.SaveRDVCoupureHorsCampagneCompleted += (ss, args) =>
         {
             try
             {
                 if (args.Cancelled || args.Error != null)
                 {
                     string error = args.Error.Message;
                     Message.ShowError("Error à l'appel du service", "SearchCampagne");
                     return;
                 }
                 if (args.Result == true)
                 {
                     Message.ShowInformation("Mise a jour validée", "Rendez-vous");
                     this.DialogResult = false;
                     return;
                 }
                 this.DialogResult = false;
             }
             catch (Exception ex)
             {
                 Message.ShowError(ex, Galatee.Silverlight.Resources.Langue.errorTitle);
             }
         };
     }
     catch (Exception ex)
     {
         Message.ShowError(ex.Message, Galatee.Silverlight.Resources.Langue.errorTitle);
     }
 }