Beispiel #1
0
 private void buttonAddPhone_Click(object sender, EventArgs e)
 {
     var phoneForm = new PhoneForm(_repository, listBoxUsers.SelectedItem.ToString());
     phoneForm.ShowDialog(this);
     var s = listBoxUsers.SelectedItem.ToString();
     var n = _repository.GetPhone(s);
     ViewPhones(n);
 }
Beispiel #2
0
        private void buttonAddNumber_Click(object sender, EventArgs e)
        {
            var form = new PhoneForm();
            form.ShowDialog();

            _phones.Add(new Phone(form.Phone,form.Description));
            dataGridViewPhones.Rows.Add(form.Phone, form.Description);
        }