示例#1
0
        public void BindSubject()
        {
            ApplicationResult objResult     = new ApplicationResult();
            SubjectMBL        objSubjectMbl = new SubjectMBL();

            objResult = objSubjectMbl.SubjectM_Select_By_School(Convert.ToInt32(Session[ApplicationSession.SCHOOLID]));
            if (objResult.resultDT.Rows.Count > 0)
            {
                gvSubject.DataSource = objResult.resultDT;
                gvSubject.DataBind();
                PanelVisibility(1);
            }
            else
            {
                PanelVisibility(2);
            }
        }
 public void BindSubject1()
 {
     try
     {
         ApplicationResult objResult     = new ApplicationResult();
         SubjectMBL        objSubjectMbl = new SubjectMBL();
         Controls          objControl    = new Controls();
         objResult = objSubjectMbl.SubjectM_Select_By_School(Convert.ToInt32(Session[ApplicationSession.SCHOOLID]));
         if (objResult != null)
         {
             objControl.BindDropDown_ListBox(objResult.resultDT, lbSrcSubject, "NameEng", "SubjectMID");
             PanelVisibility(1);
         }
         else
         {
             PanelVisibility(2);
         }
     }
     catch (Exception ex)
     {
         logger.Error("Error", ex);
         ClientScript.RegisterStartupScript(typeof(Page), "MessagePopUp", "<script>alert('Oops! There is some technical issue. Please Contact to your administrator.');</script>");
     }
 }