Esempio n. 1
0
        private void CreateDetailForm(Employee employee = null)
        {
            EmployeeDetailForm detailForm = new EmployeeDetailForm(employee);

            detailForm.MdiParent   = MdiParent;
            detailForm.WindowState = FormWindowState.Maximized;
            detailForm.Show();
            detailForm.FormClosing += DetailForm_FormClosing;
        }
        private void CreateDetailForm(Employee employee = null)
        {
            EmployeeDetailForm detailForm = new EmployeeDetailForm(employee, security, objectSpaceProvider)
            {
                MdiParent   = MdiParent,
                WindowState = FormWindowState.Maximized
            };

            detailForm.Show();
            detailForm.FormClosing += (s, e) => {
                securedObjectSpace.Refresh();
                employeeGrid.DataSource = securedObjectSpace.GetBindingList <Employee>();
            };
        }