public void LoadSubAgency() { try { ((BasePage)Page).WrtActivityLog(long.MinValue, "LoadSubAgency method in user control getting error in medical search screen.", "LOADDATA"); if (State.GPV((int)SetupParams.EnableSubAgency, KPIHlp.CVI32(hdnJurisId.Value)) == "1") { long ObjAgency = new PersonnelBL().GetDefaultAgency(State.sPFID, KPIHlp.CVI32(hdnJurisId.Value)); cddSubAgency.JurisData(null, null); if (ObjAgency != long.MinValue) { cddSubAgency.KPISelectedCodeValue = ObjAgency.ToString(); ((HtmlInputHidden)(((BasePage)this.Page).FindControl("hdnJurisSubAgencyID"))).Value = ObjAgency.ToString(); } else { ((HtmlInputHidden)(((BasePage)this.Page).FindControl("hdnJurisSubAgencyID"))).Value = string.Empty; } } LoginSubRoleCheck(); } catch (Exception objErr) { State.KPILog.Info(" LoadSubAgency method getting error in medical search screen "); ((BasePage)Page).ShowMsg(MsgType.Error, FrwkMsg.PAGE_ERR, objErr); } }
public void LoginSubRoleCheck() { int iJurisID = KPIHlp.CVI32(hdnJurisId.Value); long ObjAgency = new PersonnelBL().GetDefaultAgency(State.sPFID, iJurisID); if (new CMSHlp().ChekLoginRoleAndSubagency(ObjAgency, iJurisID)) { cddSubAgency.DropDown.Enabled = true; cddSubAgency.KPISecurity = "ACI"; } else { cddSubAgency.DropDown.Enabled = false; cddSubAgency.KPISecurity = "N"; } }