private void btnGrdmain_AddNew_Click(object sender, EventArgs e) { switch (_currentModule) { case "Configuration": Forms.Frm_AddNew_Zone frmAddNewZone = new Forms.Frm_AddNew_Zone(); frmAddNewZone.ShowDialog(); ClearAllItemsForRefresh(); BindConfigurationData(); break; case "Schedule": Forms.Frm_AddNew_Schedule frmAddNewSchedule = new Forms.Frm_AddNew_Schedule(); frmAddNewSchedule.ShowDialog(); ClearAllItemsForRefresh(); BindScheduleData(); break; case "LoadShed": HandleInformationMesssage("Load shedding data can not be saved! Data is only for control purposes!"); break; case "Rules": Forms.Frm_AddNew_RuleSet frmAddNewRuleSet = new Forms.Frm_AddNew_RuleSet(); frmAddNewRuleSet.ShowDialog(); break; } }