Пример #1
0
        private void btnModify_Click(object sender, EventArgs e)
        {
            AddRecord frm = new AddRecord(_guid, this);

            frm.ShowDialog(this);

            btnFilter_Click(sender, e);
            RefreshTables();
            //dataGridViewPatient.DataSource = null;
            //dataGridViewOrder.DataSource = null;
            //dataGridViewReport.DataSource = null;
        }
Пример #2
0
 //add record to table
 private void AddRecordButton_Click(object sender, RoutedEventArgs e)
 {
     if (ValidateInputFields())
     {
         if (ValidateInputFormat())
         {
             AddRecord addRecord = new AddRecord(con.Connect());
             addRecord.AddRec(fieldsData);
             LoadRecords();
         }
     }
 }
Пример #3
0
        private void btnAdd_Click(object sender, EventArgs e)
        {
            AddRecord frm = new AddRecord(this);

            frm.ShowDialog(this);

            if (dataGridViewIndex.Rows.Count > 0)
            {
                dataGridViewIndex.Rows[dataGridViewIndex.Rows.Count - 1].Cells[0].Selected = true;
                dataGridViewIndex.Rows[dataGridViewIndex.Rows.Count - 1].Selected          = true;
            }
            dataGridViewIndex.Focus();
        }
Пример #4
0
 private static void CheckWin(Board board, DispatcherTimer dispatcherTimer, Grid grid)
 {
     if (numbersOfVisible == board.numbersOfMines)
     {
         gameWon = true;
         Image faceImage = grid.FindName("faceImage") as Image;
         faceImage.Source = new BitmapImage(new Uri("/Minesweeper;component/img/faceWin.png", UriKind.Relative));
         dispatcherTimer.Stop();
         AddRecord addRecord = new AddRecord(time);
         addRecord.ShowDialog();
         DataBaseWindow dataBaseWindow = new DataBaseWindow();
         dataBaseWindow.ShowDialog();
     }
 }
Пример #5
0
 public bool AddRecordEx(AddRecord command) => Resolve(command);