Exemplo n.º 1
0
        private void btnModifyDepartment_Click(object sender, EventArgs e)
        {
            ModifyDepartment m = new ModifyDepartment();

            m.Show();
            Hide();
        }
Exemplo n.º 2
0
        private void editDepartmentToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (modifyDepartment == null || modifyDepartment.IsDisposed)
            {
                modifyDepartment = new ModifyDepartment();
            }

            if (tabControl.Contains(modifyDepartment))
            {
                tabControl.TabPages[modifyDepartment].Select();
            }
            else
            {
                modifyDepartment.Text = "Modify Department";
                tabControl.TabPages.Add(modifyDepartment);
                tabCount++;
            }
        }