Exemplo n.º 1
0
        private void UpdateDetailsButtonClick(object sender, RoutedEventArgs e)
        {
            UpdateTraineeWindow Update = new UpdateTraineeWindow(new Trainee(Trainee));

            Update.Closed += DetailsUpdated;
            Update.Show();
        }
        private void UpdateTrainee_Click(object sender, RoutedEventArgs e)
        {
            if (traineesListView.SelectedItem == null)
            {
                MessageBox.Show("Please select a trainee to update from the list");
                return;
            }
            Trainee             trainee             = traineesListView.SelectedItem as Trainee;
            UpdateTraineeWindow updateTraineeWindow = new UpdateTraineeWindow(trainee);

            IsEnabled = false;
            updateTraineeWindow.Show();
            updateTraineeWindow.Closed += ChildWindowClosed;
        }