protected void Page_Load(object sender, EventArgs e) { try { se1 = (this.Master.Master as Site1).se1; if (!IsPostBack) { int scode = Convert.ToInt32(Session["scode"]); string scuser = Session["username"] + ""; List <string> studytypessofar = (from row in se1.SCAnswers where row.Scode == scode && row.SCEmailid == scuser select row.studytype).ToList(); List <string> studytypes = (from row in se1.StudyQuestions where !(studytypessofar).Contains(row.StudyType) select row.StudyType).Distinct() .ToList(); DropDownList1.DataSource = studytypes; DropDownList1.DataBind(); } } catch (Exception exp) { lblmsg.Text = "sorry for inconvenience :" + exp.ToString(); } }
protected void Page_Load(object sender, EventArgs e) { se1 = (this.Master.Master as Site1).se1; if (!IsPostBack) { int scode = Convert.ToInt32(Session["scode"]); String stype = Session["stype"] + ""; StudyQuestion sq = (from row in se1.StudyQuestions where row.Scode == scode && row.StudyType == stype select row).FirstOrDefault(); if (sq != null) { TextBox1.Text = sq.q1; TextBox2.Text = sq.q2; TextBox31.Text = sq.q3; TextBox4.Text = sq.q4; TextBox5.Text = sq.q5; TextBox61.Text = sq.q6; TextBox71.Text = sq.q7; ViewState["mode"] = "edit"; } else { ViewState["mode"] = "save"; } } }
protected void Page_Load(object sender, EventArgs e) { se1 = (this.Master.Master as Site1).se1; if (!IsPostBack) { } }
protected void Page_Load(object sender, EventArgs e) { try { se1 = (this.Master.Master as Site1).se1; if (!IsPostBack) { String saemailid = Session["username"] + ""; rbStudyRadios.DataSource = (from row in se1.Studies where row.saemailid == saemailid select row).ToList(); rbStudyRadios.DataTextField = "StudyName"; rbStudyRadios.DataValueField = "SCode"; rbStudyRadios.DataBind(); if (rbStudyRadios.Items.Count == 0) { Button1.Visible = false; lblmsg.Text = "no studies found!"; } } } catch (Exception exp) { lblmsg.Text = "sorry for inconvenience :" + exp.ToString(); } }
protected void Page_Load(object sender, EventArgs e) { se1 = (this.Master.Master as Site1).se1; if (!IsPostBack) { GridView1.DataSource = se1.SAUsers.ToList(); GridView1.DataBind(); } }
protected void Page_Load(object sender, EventArgs e) { try { se1 = (this.Master.Master as Site1).se1; if (!IsPostBack) { string SCEmailid = Session["username"] + ""; int scode = Convert.ToInt32(Session["scode"]); // check for already answered this survey //List<SCAnswer> scans2 = // (from scans in se1.SCAnswers select scans).ToList(); //if(scans2.Count()>0) //{ // Response.Redirect("scdashboard.aspx"); // return; //} StudyQuestion sq = (from question in se1.StudyQuestions where question.Scode == scode && question.StudyType == "CTHQ" select question).FirstOrDefault(); if (sq != null) { TextBox1.Text = sq.q1; TextBox2.Text = sq.q2; String[] values; TextBox31.Text = sq.q3; TextBox4.Text = sq.q4; TextBox5.Text = sq.q5; values = sq.q6.Split('$'); CheckBoxList6.DataSource = values; CheckBoxList6.DataBind(); } else { } } } catch (Exception exp) { lblmsg.Text = "sorry for inconvenience :" + exp.ToString(); } }
protected void Page_Load(object sender, EventArgs e) { se1 = (this.Master.Master as Site1).se1; if (!IsPostBack) { string SCEmailid = Session["username"] + ""; int scode = Convert.ToInt32(Session["scode"]); // check for already answered this survey //List<SCAnswer> scans2 = // (from scans in se1.SCAnswers select scans).ToList(); //if(scans2.Count()>0) //{ // Response.Redirect("scdashboard.aspx"); // return; //} StudyQuestion sq = (from question in se1.StudyQuestions where question.Scode == scode && question.StudyType == "CTEQ" select question).FirstOrDefault(); if (sq != null) { TextBox1.Text = sq.q1; TextBox2.Text = sq.q2; String[] values; values = sq.q3.Split('$'); TextBox31.Text = values[0]; TextBox32.Text = values[1]; TextBox4.Text = sq.q4; TextBox5.Text = sq.q5; values = sq.q6.Split('$'); TextBox61.Text = values[0]; TextBox62.Text = values[1]; values = sq.q7.Split('$'); TextBox71.Text = values[0]; TextBox72.Text = values[1]; } else { } } }
protected void Page_Load(object sender, EventArgs e) { se1 = (this.Master.Master as Site1).se1; if (!IsPostBack) { try { int scode = Convert.ToInt32(Session["scode"]); Study study = se1.Studies.Find(scode); TextBox1.Text = study.ConsentForm; } catch (Exception exp) { lblmsg.Text = "sorry for inconvenience :" + exp.ToString(); } } }
protected void Page_Load(object sender, EventArgs e) { try { se1 = (this.Master.Master as Site1).se1; if (!IsPostBack) { int scode = Convert.ToInt32(Session["scode"]); List <string> studytypessofar = (from row in se1.StudyQuestions where row.Scode == scode select row.StudyType).Distinct().ToList(); if (studytypessofar.Count() >= 3) { Button2.Visible = true; //Button6.Visible = true; TextBox1.Visible = true; int c = (from row in se1.SCUsers where row.SCode == scode select row.SCEmailid).Count(); Study s = se1.Studies.Find(scode); if (c > 0) { Button2.Text += ("Accounts Already Exists"); } } else { Button2.Visible = false; //Button6.Visible = false; TextBox1.Visible = false; } } } catch (Exception exp) { lblmsg.Text = "sorry for inconvenience :" + exp.ToString(); } }
protected void Page_Load(object sender, EventArgs e) { se1 = (this.Master.Master as Site1).se1; }
protected void Page_Load(object sender, EventArgs e) { se1 = (this.Master.Master as Site1).se1; studyvalue = Session[""] + ""; }