Exemple #1
0
 private void button2_Click(object sender, EventArgs e)
 {
     try
     {
         var bindingList = aContactH.Show(aContact);
         var source      = new BindingSource(bindingList, null);
         dataGridView1.DataSource = source;
     }
     catch (DataExistence ex)
     {
         MessageBox.Show(ex.Message, "Data Entry Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message, "Data Entry Error - Unhandled", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }