Beispiel #1
0
        private void btnAdd_Click(object sender, EventArgs e)
        {
            var          frmCustomer = new FormCustomerMaintenance();
            DialogResult res         = frmCustomer.ShowDialog();

            if (res == DialogResult.OK)
            {
                LoadData();
            }
        }
Beispiel #2
0
        private void btnEdit_Click(object sender, EventArgs e)
        {
            var          email       = CustomersList.CurrentRow.Cells[2].Value.ToString();
            var          customer    = CustomerApi.CustomersList.FirstOrDefault(t => t.Email == email);
            var          frmCustomer = new FormCustomerMaintenance(customer);
            DialogResult res         = frmCustomer.ShowDialog();

            if (res == DialogResult.OK)
            {
                LoadData();
            }
        }