예제 #1
0
 private void copy_Click(object sender, RoutedEventArgs e)
 {
     if (dg.SelectedIndex > -1)
     {
         StudentsDialog dialog = new StudentsDialog(mode.Copy, this, (int)dg.SelectedValue);
         dialog.ShowDialog();
     }
     else
     {
         MessageBox.Show("Не выбрано поле!");
     }
 }
예제 #2
0
        private void add_Click(object sender, RoutedEventArgs e)
        {
            StudentsDialog dialog = new StudentsDialog(mode.Add, this);

            dialog.ShowDialog();
        }
예제 #3
0
        private void Dg_MouseDoubleClick(object sender, MouseButtonEventArgs e)
        {
            StudentsDialog dialog = new StudentsDialog(mode.Update, this, (int)dg.SelectedValue);

            dialog.ShowDialog();
        }