Ejemplo n.º 1
0
 private void tsBtnEdit_Click(object sender, System.EventArgs e)
 {
     if (this.bsBanks.get_Current() is Bank)
     {
         AddChangeBankForm form = new AddChangeBankForm(this.bsBanks.get_Current() as Bank);
         if (form.ShowDialog(this) == System.Windows.Forms.DialogResult.OK)
         {
             this.bsBanks.RemoveCurrent();
             this.bsBanks.Add(form.Bank);
             this.bsBanks.set_Position(this.bsBanks.IndexOf(form.Bank));
         }
     }
 }
Ejemplo n.º 2
0
 private void tsBtnAdd_Click(object sender, System.EventArgs e)
 {
     AddChangeBankForm form = new AddChangeBankForm(this.tbName.get_Text(), this.tbCity.get_Text(), this.mtbCode.get_Text(), this.mtbBIK.get_Text(), this.mtbLoro.get_Text());
     if (form.ShowDialog(this) == System.Windows.Forms.DialogResult.OK)
     {
         this.bsBanks.Add(form.Bank);
         this.bsBanks.set_Position(this.bsBanks.IndexOf(form.Bank));
     }
 }