// -----------------------------department---------------------------------
        private void viewAllToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (viewDepartmentForm == null)
            {
                viewDepartmentForm           = new ViewDepartmentForm();
                viewDepartmentForm.MdiParent = this;

                viewDepartmentForm.FormClosed += delegate(object o, FormClosedEventArgs args) { viewDepartmentForm = null; };
                viewDepartmentForm.Show();
            }

            else
            {
                viewDepartmentForm.Activate();
            }
        }
예제 #2
0
        private void refreshListButton_Click(object sender, EventArgs e)
        {
            ViewDepartmentForm viewDepartmentForm = new ViewDepartmentForm();


            if (mainForm == null)
            {
                mainForm = new MainForm();
                mainForm.Show();
            }
            else
            {
                mainForm.Activate();
            }
            viewDepartmentForm.MdiParent = mainForm;

            viewDepartmentForm.Show();
        }