public MainWindow(ClientController controller) { InitializeComponent(); Controller = controller; EventSignedUpDataTable = new DataTable(); EventSignedUpDataTable.Columns.Add("Event", typeof(Event)); EventSignedUpDataTable.Columns.Add("Age Group", typeof(AgeGroup)); EventSignedUpDataTable.Columns.Add("Signed Up", typeof(long)); AgeGroupEventDataTable = new DataTable(); AgeGroupEventDataTable.Columns.Add("Name", typeof(string)); AgeGroupEventDataTable.Columns.Add("Age", typeof(int)); AgeGroupEventDataTable.Columns.Add("No. Events", typeof(int)); foreach (AgeGroup a in Enum.GetValues(typeof(AgeGroup))) { AgeGroupComboBox.Items.Add(a); } FirstEventComboBox.Items.Add(Event.E50M); FirstEventComboBox.Items.Add(Event.E100M); AgeGroupEventGridView.DataSource = AgeGroupEventDataTable; foreach (EventCountDTO e in Controller.GetEventsNumber()) { EventSignedUpDataTable.Rows.Add(e.Event, e.AgeGroup, e.Count); } EventSignedUpGridView.DataSource = EventSignedUpDataTable; Controller.UpdateEvent += UserUpdate; }