protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { FST.Common.Business_Interface bi = new FST.Common.Business_Interface(); // load the races (or ethnicities) into the page DataTable dt = bi.GetRaces(); this.ddlRace.DataSource = dt; DataRow row = dt.NewRow(); row["FieldName"] = DBNull.Value; row["FieldValue"] = DBNull.Value; dt.Rows.Add(row); this.ddlRace.DataTextField = "FieldName"; this.ddlRace.DataValueField = "FieldValue"; this.ddlRace.DataBind(); this.ddlRace.Text = ""; dt.Clear(); // get the loci (for all lab kits) dt = bi.GetLocus(Guid.Empty); this.ddlLocus.DataSource = dt; row = dt.NewRow(); row["FieldName"] = DBNull.Value; row["FieldValue"] = DBNull.Value; dt.Rows.Add(row); this.ddlLocus.DataTextField = "FieldName"; this.ddlLocus.DataValueField = "FieldValue"; this.ddlLocus.DataBind(); this.ddlLocus.Text = ""; dt.Clear(); // get the alleles for the selected locus dt = bi.GetAlleles(this.ddlLocus.SelectedValue); this.ddlAlleleNo.DataSource = dt; row = dt.NewRow(); row["FieldName"] = DBNull.Value; row["FieldValue"] = DBNull.Value; dt.Rows.Add(row); this.ddlAlleleNo.DataTextField = "FieldName"; this.ddlAlleleNo.DataValueField = "FieldValue"; this.ddlAlleleNo.DataBind(); this.ddlAlleleNo.Text = ""; dt.Clear(); // get the frequencies dt = bi.GetFrequencyData(); this.gvFreqView.DataSource = dt; this.gvFreqView.DataBind(); } }