/// <summary> /// Bind Subject Category From the table Scrl_Category_SubjectTbl /// </summary> private void BindSubjectList() { DataTable dtSub = new DataTable(); DataSet ds = new DataSet(); if (Convert.ToString(ViewState["intGroupId"]) != "" && Convert.ToString(ViewState["intGroupId"]) != null) { objgrp.inGroupId = Convert.ToInt32(ViewState["intGroupId"]); } else { objgrp.inGroupId = 0; } dtSub = objgrpDB.GetDataTable(objgrp, DA_Scrl_UserGroupDetailTbl.Scrl_UserGroupDetailTbl.GetContextByGroupID); // LstSubjCategory.DataValueField = "intCategoryId"; // LstSubjCategory.DataTextField = "strCategoryName"; if (dtSub.Rows.Count > 0) { // LstSubjCategory.DataSource = dtSub; // LstSubjCategory.DataBind(); LstProfSubjCategory.DataSource = dtSub; LstProfSubjCategory.DataBind(); } else { divlstProfSubjCategory.Visible = false; // LstSubjCategory.DataSource = null; // LstSubjCategory.DataBind(); LstProfSubjCategory.DataSource = null; LstProfSubjCategory.DataBind(); } }
/// <summary> /// Bind Subject Category From the table Scrl_Category_SubjectTbl /// </summary> private void BindSubjectList() { DataTable dtSub = new DataTable(); DataSet ds = new DataSet(); objgrp.inGroupId = Convert.ToInt32(ViewState["intGroupId"]); dtSub = objgrpDB.GetDataTable(objgrp, DA_Scrl_UserGroupDetailTbl.Scrl_UserGroupDetailTbl.GetContextByGroupID); if (dtSub.Rows.Count > 0) { LstSubjCategory.DataSource = dtSub; LstSubjCategory.DataBind(); LstProfSubjCategory.DataSource = dtSub; LstProfSubjCategory.DataBind(); } else { LstSubjCategory.DataSource = null; LstSubjCategory.DataBind(); LstProfSubjCategory.DataSource = null; LstProfSubjCategory.DataBind(); } }