Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using Students.Core;
- using Students.Core.Enums;
- using Students.Core.Types;
- using System;
- using System.Collections.Generic;
- using System.Collections.ObjectModel;
- using System.ComponentModel;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace StudentsWPF.ViewModels
- {
- class MainWindowModel : INotifyPropertyChanged
- {
- public string FilePath { get; set; }
- public Student CurrentStudent { get; set; }
- public StudentsClass StudentsCollection { get; set; }
- public ObservableCollection<Student> StudentsObservableCollection { get; set; }
- public ObservableCollection<string> StudentGenderObservableCollection { get; set; }
- public MainWindowModel()
- {
- Model m = new Model();
- StudentsClass sc = m.Load(@"D:\pers\Downloads\Telegram Desktop\Students.xml");
- StudentsObservableCollection = new ObservableCollection<Student>(sc.StudentsList);
- List<string> gender = new List<string>()
- {
- Gender.MALE.ToString(),
- Gender.FEMALE.ToString()
- };
- StudentGenderObservableCollection = new ObservableCollection<string>(gender);
- }
- public event PropertyChangedEventHandler PropertyChanged;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement