コード例 #1
0
        protected void DataBind_Quarter()
        {
            Quarter focusArea = new Quarter();

            ddlQuarter.DataSource     = focusArea.GetAllQuarters();
            ddlQuarter.DataTextField  = "QuarterName";
            ddlQuarter.DataValueField = "QuarterId";
            ddlQuarter.DataBind();
        }
コード例 #2
0
        private void QuarterDataBind()
        {
            Quarter quarter = new Quarter();

            ddlQuarters.DataSource     = quarter.GetAllQuarters();
            ddlQuarters.DataTextField  = "QuarterName";
            ddlQuarters.DataValueField = "QuarterID";
            ddlQuarters.DataBind();

            ddlQuarters.Items.Add(new ListItem("All", "0"));

            ddlQuarters.SelectedValue = quarter.GetCurrentQuarterId().ToString();
        }