private void LoginBtn_Click(object sender, RoutedEventArgs e)
        {
            HomeUC homeUC = new HomeUC();

            Grid.SetColumn(homeUC, 1);
            Grid.SetRow(homeUC, 2);
            ((Grid)((Grid)Application.Current.MainWindow.Content).Children[1]).Children.Add(homeUC);
            Close();
        }
 private void ButtonHome_Click(object sender, RoutedEventArgs e)
 {
     //  essai();
     homeUC = new HomeUC();
     ((MainWindow)System.Windows.Application.Current.MainWindow).inner_grid.Children.Clear();
     ((MainWindow)System.Windows.Application.Current.MainWindow).content_grid.Children.Clear();
     ((MainWindow)System.Windows.Application.Current.MainWindow).profile_grid.Children.Clear();
     ((MainWindow)System.Windows.Application.Current.MainWindow).full_content_grid.Children.Clear();
     ((MainWindow)System.Windows.Application.Current.MainWindow).inner_grid.Children.Add(homeUC);
 }
Example #3
0
        //MenuUC menuUC;
        //BoxSubMenuUC boxSubMenuUC;
        //ListActiveUC listActive;
        //Menu_GlobeUC menu_GlobeUC;

        public MainWindow()
        {
            InitializeComponent();
            Global.Instance.WindowMain = this;
            homeUC = new HomeUC();

            grdHomeUC.Children.Add(homeUC);
            //grdMenuUC.Children.Add(menuUC);
            //grdBoxSubMenuUC.Children.Add(boxSubMenuUC);
            //grdListActiveUC.Children.Add(listActive);
            //grdMenu_GlobeUC.Children.Add(menu_GlobeUC);
        }
Example #4
0
        private void MyCommand_UpdateIceCream(string parameter)
        {
            GraduateICModel.IceCream.marks.Add((Int32)(GraduationUC.Grades.Value));

            if (Image != null)
            {
                GraduateICModel.IceCream.images.Add(Image.ToString());
            }
            GraduateICModel.IceCream.marks[0] = (Int32)GraduateICModel.IceCream.marks.Skip(1).Take(GraduateICModel.IceCream.marks.Count - 1).Average();
            System.Windows.MessageBox.Show("Thanks for your appreciation !! See you soon !!", "Thanks", MessageBoxButton.OK, MessageBoxImage.Exclamation);
            homeUC = new HomeUC();
            ((MainWindow)System.Windows.Application.Current.MainWindow).inner_grid.Children.Clear();
            ((MainWindow)System.Windows.Application.Current.MainWindow).content_grid.Children.Clear();
            ((MainWindow)System.Windows.Application.Current.MainWindow).profile_grid.Children.Clear();
            ((MainWindow)System.Windows.Application.Current.MainWindow).inner_grid.Children.Add(homeUC);


            GraduateICModel.IceCream.UpdateData();
            GraduateICModel.UpdateIceCream(GraduationUC.SelectedIceCream, GraduateICModel.IceCream);
        }