protected void Page_PreRender(object sender, EventArgs e) { if (!Page.IsPostBack) { string appContext; if (Request.QueryString != null && Request.QueryString.Get("c") != null) { appContext = Request.QueryString.Get("c").ToString(); } else { appContext = ""; } divWorkArea.ViewStateMode = System.Web.UI.ViewStateMode.Disabled; // display the problem report per the ID passed if ((bool)SessionManager.ReturnStatus) { divPageBody.Visible = true; decimal caseID; if (Decimal.TryParse(SessionManager.ReturnObject.ToString(), out caseID)) { SetCaseCtl(new ProblemCaseCtl().Initialize(null, appContext)); CaseCtl().Load(caseID, appContext); if (CaseCtl().IsClear() == false) { bool bNotify = false; if (CaseCtl().problemCase.ProbCase.PROBCASE_TYPE == "EHS") { lblCasePrefixEHS.Visible = true; lblCasePrefix.Visible = false; } CaseCtl().LoadPersonSelectList(true); lblCaseID.Text = CaseCtl().problemCase.CaseID; CaseCtl().PageMode = PageUseMode.ViewOnly; uclCaseRpt.SetPageMode(); uclCaseRpt.BindCase0(); uclCaseRpt.BindCase1(bNotify); uclCaseRpt.BindCase2(); uclCaseRpt.BindCase3(); uclCaseRpt.BindCase4(); uclCaseRpt.BindCase5(); uclCaseRpt.BindCase6(); uclCaseRpt.BindCase7(); uclCaseRpt.BindCase8(bNotify); uclCaseRpt.BindIncidentList(CaseCtl().problemCase.IncidentList); uclCaseRpt.BindPartIssueItemList(CaseCtl().problemCase.PartIssueItemList); SQMBasePage.EnableControls(divWorkArea.Controls, false); SQMBasePage.DisplayButtons(divWorkArea.Controls, false); } } // display error message ... SessionManager.ClearReturns(); } } else { } }