protected void Page_Load(object sender, EventArgs e) { SqlConnClass objSqlConnClass = new SqlConnClass(); TextAreaClass objTextAreaClass; objTextAreaClass = new TextAreaClass(objSqlConnClass.OpenConnection()); DataSet DSCMS = objTextAreaClass.TxA_Get_TextAreas(Request.QueryString["cmstype"].ToString(), "2"); try { if (DSCMS.Tables[0].Rows.Count > 0)//There needs to be at least 1 row { lblTextAreaHtml.Text = DSCMS.Tables[0].Rows[0]["TextAreaHTML"].ToString(); lblHeading.Text = DSCMS.Tables[0].Rows[0]["strDefaultName"].ToString(); #region Insert visited log details AppLib.InsertVisitedSectionDetails(lblHeading.Text); #endregion } } catch { } finally { objSqlConnClass.CloseConnection(); objSqlConnClass = null; objTextAreaClass = null; DSCMS = null; } }
private void BindCMSText() { TextAreaClass objTextAreaClass; SqlConnClass objSqlConnClass = new SqlConnClass(); objTextAreaClass = new TextAreaClass(objSqlConnClass.OpenConnection()); DataSet DS = objTextAreaClass.TxA_Get_TextAreas("ActivityCalendar", "1"); lblActivitycalender.Text = DS.Tables[0].Rows[0]["TextAreaHTML"].ToString(); DS = null; objTextAreaClass = null; objSqlConnClass = null; }
private void BindCMSText_Pro() { TextAreaClass objTextAreaClass; SqlConnClass objSqlConnClass = new SqlConnClass(); objTextAreaClass = new TextAreaClass(objSqlConnClass.OpenConnection()); DataSet DS = objTextAreaClass.TxA_Get_TextAreas("Meal_Proteins", "1"); lblPROTEINS.Text = DS.Tables[0].Rows[0]["TextAreaHTML"].ToString(); DS = null; objTextAreaClass = null; objSqlConnClass = null; }
private void BindCMSText() { TextAreaClass objTextAreaClass; SqlConnClass objSqlConnClass = new SqlConnClass(); objTextAreaClass = new TextAreaClass(objSqlConnClass.OpenConnection()); DataSet DS = objTextAreaClass.TxA_Get_TextAreas("ToolsResources", "1"); lblToolsResources.Text = DS.Tables[0].Rows[0]["TextAreaHTML"].ToString(); DS = null; objTextAreaClass = null; objSqlConnClass = null; }
protected void Page_Load(object sender, EventArgs e) { objTextAreaClass = new TextAreaClass(objSqlConnClass.OpenConnection()); if (Session["MODE_CURRENT"] == null) { Session["MODE_CURRENT"] = "NORMAL"; } if (ViewState["gsTextAreaId"] != null) { gsTextAreaId = ViewState["gsTextAreaId"].ToString(); } }
private void BindCMSText() { TextAreaClass objTextAreaClass; SqlConnClass objSqlConnClass = new SqlConnClass(); objTextAreaClass = new TextAreaClass(objSqlConnClass.OpenConnection()); DataSet DS = objTextAreaClass.TxA_Get_TextAreas("DailyCaloricRequirement", "2"); lblDCRequirmentHTMLText.Text = DS.Tables[0].Rows[0]["TextAreaHTML"].ToString(); DS = objTextAreaClass.TxA_Get_TextAreas("DailyCaloricRequirementHowActiveAreYou", "2"); lblActiveAreYouHTMLText.Text = DS.Tables[0].Rows[0]["TextAreaHTML"].ToString(); /* if (DS.Tables[0].Rows[0]["TextAreaHTML"].ToString().Length > 100) { lblDCRequirmentHTMLText.Text = DS.Tables[0].Rows[0]["TextAreaHTML"].ToString().Substring(0, 100); } else { lblDCRequirmentHTMLText.Text = DS.Tables[0].Rows[0]["TextAreaHTML"].ToString(); }*/ DS = null; objTextAreaClass = null; objSqlConnClass = null; }
protected void Page_Load(object sender, EventArgs e) { objTextAreaClass = new TextAreaClass(objSqlConnClass.OpenConnection()); if (Request.QueryString["TextAreaName"] != null) { gsTextAreaName = Request.QueryString["TextAreaName"].ToString(); } if (Request.QueryString["refreshButtonId"] != null) { txtBtnRefreshID.Text = Request.QueryString["refreshButtonId"].ToString(); } if (ViewState["gsTextAreaId"] != null) { gsTextAreaId = ViewState["gsTextAreaId"].ToString(); } if (ViewState["gbPreviewMode"] != null) { gbPreviewMode = Convert.ToBoolean(ViewState["gbPreviewMode"]); } }
/// <summary> /// BindDetails() function used to bind all the details that need to be display on the page load. /// </summary> private void BindCMSDetails() { SqlConnClass objSqlConnClass = new SqlConnClass(); TextAreaClass objTextAreaClass; objTextAreaClass = new TextAreaClass(objSqlConnClass.OpenConnection()); DataSet DSCMS = objTextAreaClass.TxA_Get_TextAreas("MyNutritionOverview", "2"); try { if (DSCMS.Tables[0].Rows.Count > 0)//There needs to be at least 1 row { if (DSCMS.Tables[0].Rows[0]["TextAreaHTML"].ToString().Length > 900) lblNutritionOverview.Text = DSCMS.Tables[0].Rows[0]["TextAreaHTML"].ToString().Substring(0, 900); else lblNutritionOverview.Text = DSCMS.Tables[0].Rows[0]["TextAreaHTML"].ToString(); } } catch { } finally { objSqlConnClass.CloseConnection(); objSqlConnClass = null; objTextAreaClass = null; DSCMS = null; } }
private void BindCMSText() { TextAreaClass objTextAreaClass; SqlConnClass objSqlConnClass = new SqlConnClass(); objTextAreaClass = new TextAreaClass(objSqlConnClass.OpenConnection()); DataSet DS = objTextAreaClass.Get_MultipleCMSPagesText(); for (int i = 0; i < DS.Tables[0].Rows.Count; i++) { string strTemp = DS.Tables[0].Rows[i]["strPageName"].ToString(); if (DS.Tables[0].Rows[i]["strPageName"].ToString().ToLower().Equals("tutorialsandnavigation")) { if (DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Length > 900) lblTutorialNavigationHTMLText.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Substring(0, 900); else lblTutorialNavigationHTMLText.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString(); } else if (DS.Tables[0].Rows[i]["strPageName"].ToString().ToLower().Equals("goalsobjectives")) { if (DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Length > 900) lblGoalsObjectives.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Substring(0, 900); else lblGoalsObjectives.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString(); } else if (DS.Tables[0].Rows[i]["strPageName"].ToString().ToLower().Equals("levelofintensity")) { if (DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Length > 900) lblLevelOfIntensity.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Substring(0, 900); else lblLevelOfIntensity.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString(); } else if (DS.Tables[0].Rows[i]["strPageName"].ToString().ToLower().Equals("howwemeasure")) { if (DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Length > 900) lblHowWeMeasure.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Substring(0, 900); else lblHowWeMeasure.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString(); } else if (DS.Tables[0].Rows[i]["strPageName"].ToString().ToLower().Equals("nutritioncenter")) { if (DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Length > 900) lblNutritionCenter.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Substring(0, 900); else lblNutritionCenter.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString(); } else if (DS.Tables[0].Rows[i]["strPageName"].ToString().ToLower().Equals("personalfitness")) { if (DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Length > 900) lbPersonalFitness.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Substring(0, 900); else lbPersonalFitness.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString(); } else if (DS.Tables[0].Rows[i]["strPageName"].ToString().ToLower().Equals("wellnessdairy")) { if (DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Length > 900) lblWellnessDiary.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Substring(0, 900); else lblWellnessDiary.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString(); } else if (DS.Tables[0].Rows[i]["strPageName"].ToString().ToLower().Equals("wellnessdairyforum")) { if (DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Length > 900) lblWellnessDairyForum.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString().Substring(0, 900); else lblWellnessDairyForum.Text = DS.Tables[0].Rows[i]["TextAreaHTML"].ToString(); } } DS = null; objTextAreaClass = null; objSqlConnClass.CloseConnection(); objSqlConnClass = null; }
public static void Init(AppPressDemo p, TextAreaClass TextArea) { TextArea.Help.val = "<a href='https://docs.google.com/document/d/1goW6BxoZp1WK12ZCcmg8RqVgADifn8yYZSZoGjpUeRo/edit#heading=h.a24q3ds594fi' target='_blank'><i class=\"fa fa-question-circle\"></i></a>"; }