protected override void OnInit(EventArgs e) { goal = DR_Goals.Get(QueryStringID); goalViewMini.GoalID = goal.ID; tagViewList.CellDataBinding += new GridViewDataBindHandler<HyperLink, DR_Tags>(tagViewList_CellDataBinding); base.OnInit(e); }
protected override void OnInit(EventArgs e) { string idstring = Request.QueryString["id"]; string typestring = Request.QueryString["type"]; long id; try { id = Convert.ToInt64(idstring); goal = DR_Goals.Get(id); LinkNewGoal.NavigateUrl = "/goals/new"; } catch (Exception ex) { invalid = true; } if (!invalid && typestring == "p") { labelHeader.Text = "Adding parent goal to goal " + goal._Name; goalSelector.SelectGoalIntroText = "Select New Parent Goal"; type = "p"; } else if (!invalid && typestring == "c") { labelHeader.Text = "Adding child goal to goal " + goal._Name; goalSelector.SelectGoalIntroText = "Select New Child Goal"; type = "c"; } else { invalid = true; } buttonSubmit.Click += new EventHandler(buttonSubmit_Click); buttonCancel.Click += new EventHandler(buttonCancel_Click); base.OnInit(e); }
public GoalDefinitionControl(DR_Goals goal) : base() { }
public GoalViewMini(DR_Goals goal) : base() { this.goal = goal; }
private void InitData(DR_Goals goal) { if (goal != null) { DR_Agents agent = DR_Agents.Get(goal._IDAgentCreated); LabelGoalName.Controls.Add(new LiteralControl("<h3><b>" + goal._Name + "</b></h3>")); LabelAgentCreated.Agent = agent; LabelTimeCreated.UtcTime = goal.TimeCreatedUTC; //DataParentGoals.Goal = goal; //DataChildGoals.Goal = goal; HyperLinkAddParent.NavigateUrl = "/goals/addvertex?id=" + goal.ID.ToString() + "&type=p"; HyperLinkAddChild.NavigateUrl = "/goals/addvertex?id=" + goal.ID.ToString() + "&type=c"; } else { LabelGoalName.Controls.Add(new LiteralControl("Invalid Goal ID")); } }