private void ShowMainForm() { if (TimesheetForm == null) { TimesheetForm = new frmMain(TimeCard); TimesheetForm.Closed += MainForm_Closed; // avoid reshowing a disposed form TimesheetForm.Show(); } else { TimesheetForm.Activate(); } }
private void ShowEditProjectForm() { if (EditProjectForm == null) { EditProjectForm = new frmMain(TimeCard); EditProjectForm.Closed += MainForm_Closed; // avoid reshowing a disposed form EditProjectForm.Show(); } else { EditProjectForm.Activate(); } }