예제 #1
0
 private void miSave_Click(object sender, EventArgs e)
 {
     if (dataBase != null)
     {
         dataBase.Save();
     }
     else
     {
         MessageBox.Show("База данных не создана");
     }
 }
예제 #2
0
        private void miNew_Click(object sender, EventArgs e)
        {
            SaveFileDialog sfd = new SaveFileDialog();

            if (sfd.ShowDialog() == DialogResult.OK)
            {
                dataBase = new TrueFalse(sfd.FileName);
                dataBase.Add("123", true);
                dataBase.Save();
                numNumber.Minimum = 1;
                numNumber.Maximum = 1;
                numNumber.Value   = 1;
            }
        }