Example #1
0
        public AddStudentWindow()
        {
            InitializeComponent();

            student          = new BE.Student();
            this.DataContext = student;

            bl = BL.FactoryBL.GetBL();

            this.studentCampusComboBox.ItemsSource = Enum.GetValues(typeof(BE.Campus));
            this.studentGenderComboBox.ItemsSource = Enum.GetValues(typeof(BE.Gender));
        }
Example #2
0
 private void addButton_Click(object sender, RoutedEventArgs e)
 {
     try
     {
         bl.AddStudent(student);
         student          = new BE.Student();
         this.DataContext = student;
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }