示例#1
0
 /// <summary>
 /// Loads the new Search Form
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void searchToolStripMenuItem_Click(object sender, EventArgs e)
 {
     try
     {
         if (newPatientSearchForm == null)
         {
             newPatientSearchForm = new NwPatientSearch();
             newPatientSearchForm.MdiParent = this;
             newPatientSearchForm.FormClosed +=newPatientSearchForm_FormClosed;
             newPatientSearchForm.Show();
         }
         else
             newPatientSearchForm.Activate();
     }
     catch (SqlException ex)
     {
         MessageBox.Show(ex.Message, ex.GetType().ToString());
         this.Close();
     }
 }
示例#2
0
 /// <summary>
 /// Sets the new Patient Search to closed
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 void newPatientSearchForm_FormClosed(object sender, FormClosedEventArgs e)
 {
     newPatientSearchForm = null;
 }