Пример #1
0
    /// <summary>
    /// This function is used to show the details of a particularly selected record from a gridview
    /// </summary>
    public void SelectedRowData()
    {
        string    keyId = Convert.ToString(gvKnownPopulation.DataKeys[gvKnownPopulation.SelectedIndex].Value, CultureInfo.CurrentCulture);
        DataTable dt    = bi.GetDetailKnownPopulation(keyId);

        this.lblId.Text = keyId;
        this.tID.Text   = keyId;

        foreach (DataColumn dc in dt.Columns)
        {
            if (dc.ColumnName != "ID" && dc.ColumnName != "Active" && dc.ColumnName != "EthnicID")
            {
                knownProfile.Alleles[dc.ColumnName] = dt.Rows[0][dc.ColumnName].ToString();
            }
        }

        this.dlActive.Text   = dt.Rows[0]["Active"].ToString();
        this.dlRaceEdit.Text = dt.Rows[0]["EthnicID"].ToString();
        this.tID.ReadOnly    = true;
    }