public void BindSubject() { try { EWA_Common objEWA = new EWA_Common(); DL_Common objDL = new DL_Common(); objEWA.OrgId = Session["OrgId"].ToString(); objEWA.CourseId = ddlCourse.SelectedValue.ToString(); objEWA.BranchId = ddlBranch.SelectedValue.ToString(); objEWA.ClassId = ddlClass.SelectedValue.ToString(); //objEWA.DivisionId = ddlDivision.SelectedValue.ToString(); objEWA.UserCode = Session["Username"].ToString(); DataSet ds = objDL.FetchSubject_DL(objEWA); DDSubject.Items.Clear(); DDSubject.DataSource = ds; DDSubject.DataTextField = "SubjectName"; DDSubject.DataValueField = "SubjectId"; DDSubject.DataBind(); DDSubject.Items.Insert(0, new ListItem("Select", "0")); } catch (Exception exp) { GeneralErr(exp.Message.ToString()); } }
//Bind Subject #region [Bind Subject] public DataSet FatchSubject_BL(EWA_Common ObjEWA) { try { DL_Common ObjDL = new DL_Common(); DataSet ds = ObjDL.FetchSubject_DL(ObjEWA); return(ds); } catch (Exception exp) { throw exp; } }