Esempio n. 1
0
        private void BtnAdd_Click(object sender, EventArgs e)
        {
            Registration     registration     = new Registration();
            EditRegistration editRegistration = new EditRegistration(packages, registration);

            if (editRegistration.ShowDialog() == DialogResult.OK)
            {
                registrations.Add(registration);
                displayRegistrations();
            }
        }
Esempio n. 2
0
 private void editToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (listView.SelectedItems.Count != 1)
     {
         MessageBox.Show("Select one record to edit");
     }
     else
     {
         Registration     registration     = (Registration)listView.SelectedItems[0].Tag;
         EditRegistration registrationForm = new EditRegistration(packages, registration);
         if (registrationForm.ShowDialog() == DialogResult.OK)
         {
             displayRegistrations();
         }
     }
 }