private void Button_Ajouter_Click(object sender, RoutedEventArgs e)
        {
            var step2AddOrUpdate = new Step2AddOrUpdate();

            step2AddOrUpdate.DataContext = new FormToSpList {
                DataMapping = new ObservableCollection <DataMapping>()
            };
            step2AddOrUpdate.Context         = ((Config)DataContext).SharepointConfig.Context;
            step2AddOrUpdate.FormTospLists   = ((Config)DataContext).FormsToSpLists;
            step2AddOrUpdate.OpnedForNewItem = true;
            step2AddOrUpdate.Show();
            step2AddOrUpdate.FillCbBox();
        }
 private void ButtonUpdate_Click(object sender, RoutedEventArgs e)
 {
     if (lvFormsToSpLists.SelectedItem != null)
     {
         FormToSpList item = (FormToSpList)lvFormsToSpLists.SelectedItem;
         item.DataMapping = item.DataMapping ?? new ObservableCollection <DataMapping>();
         var step2AddOrUpdate = new Step2AddOrUpdate();
         step2AddOrUpdate.DataContext     = item;
         step2AddOrUpdate.OpnedForNewItem = false;
         step2AddOrUpdate.Context         = ((Config)DataContext).SharepointConfig.Context;
         step2AddOrUpdate.Show();
         step2AddOrUpdate.FillCbBox();
     }
 }