private void Create_New_Task(object sender, RoutedEventArgs e) { NewTaskWindow modalWindow = new NewTaskWindow(); if (modalWindow.ShowDialog() == true) { listView.ItemsSource = TaskController.AddItem(modalWindow.EditTask);; } }