Exemplo n.º 1
0
        public void DeleteTrainer(string name)
        {
            TrainerContainer tc = (TrainerContainer)trainerGrid.SelectedItem;

            if (tc == null)
            {
                return;
            }
            if (name == tc.Name)
            {
                DataSerializer.DeleteTrainer(tc);
                data.Remove((TrainerContainer)trainerGrid.SelectedItem);
                DataSerializer.SaveTrainerContainers(data);
            }
        }