private void btnNew_Click(object sender, RoutedEventArgs e) { try { if (memberuser.CréationAdministrateur == true) { AjouterTypeCas CLSession = new AjouterTypeCas(proxy, callback, null, memberuser); CLSession.Show(); } else { MessageBoxResult result = Xceed.Wpf.Toolkit.MessageBox.Show(Medicus.Properties.Resources.Opérationéchouée, Medicus.Properties.Resources.SiteWeb, MessageBoxButton.OK, MessageBoxImage.Error); } } catch (Exception ex) { MessageBoxResult resultc10 = Xceed.Wpf.Toolkit.MessageBox.Show(ex.Message, Medicus.Properties.Resources.SiteWeb, MessageBoxButton.OK, MessageBoxImage.Error); } }
private void btnEdit_Click(object sender, RoutedEventArgs e) { try { if (memberuser.ModificationAdministrateur == true) { SVC.TypeCa SelectMedecin = MotifDataGrid.SelectedItem as SVC.TypeCa; AjouterTypeCas CLSession = new AjouterTypeCas(proxy, callback, SelectMedecin, memberuser); CLSession.Show(); } else { MessageBoxResult result = Xceed.Wpf.Toolkit.MessageBox.Show(Medicus.Properties.Resources.Opérationéchouée, Medicus.Properties.Resources.SiteWeb, MessageBoxButton.OK, MessageBoxImage.Error); } } catch (Exception ex) { MessageBoxResult resultc10 = Xceed.Wpf.Toolkit.MessageBox.Show(ex.Message, Medicus.Properties.Resources.SiteWeb, MessageBoxButton.OK, MessageBoxImage.Error); } }