private void Button_Click(object sender, RoutedEventArgs e) { try { Glue.DeleteStud(int.Parse(DelTargetTB.Text)); } catch (Exception a) { Error.GetError(a); } MainWindow.Reset(); Close(); }