Пример #1
0
        public AjoutCollection(Objetcs.Collection coll)
        {
            ThisCollection = coll;
            InitializeComponent();
            DataContext = ThisCollection;
            var currentApp = System.Windows.Application.Current as App;

            ListGroupes.DataContext = currentApp.MyData.Colstruct;
            labelnom.DataContext    = ThisCollection;
        }
Пример #2
0
        private void CreateContentAndNext_Click(object sender, RoutedEventArgs e)
        {
            var currentApp = System.Windows.Application.Current as App;

            try
            {
                currentApp.MyData.ListCollection.Add(ThisCollection);
                CollectionGroup group = ListGroupes.SelectedItem as CollectionGroup;
                group.ListeCollection.Add(ThisCollection);
                ThisCollection = new Objetcs.Collection();
            }
            catch { var result = System.Windows.Forms.MessageBox.Show("Mauvaises données rentrées", "Fermer", System.Windows.Forms.MessageBoxButtons.OK, System.Windows.Forms.MessageBoxIcon.Exclamation); }
        }