Пример #1
0
 private void btnNewConnection_Click(object sender, EventArgs e)
 {
     using (ConnectionForm form = new ConnectionForm())
     {
         if (form.ShowDialog() == DialogResult.OK)
         {
             Connection = form.Connection;
         }
     }
 }
Пример #2
0
 private void btnEditConnection_Click(object sender, EventArgs e)
 {
     using (ConnectionForm form = new ConnectionForm())
     {
         form.Connection = Connection;
         form.EditMode   = true;
         if (form.ShowDialog() == DialogResult.OK)
         {
             Connection = form.Connection;
         }
     }
 }