示例#1
0
    private void showyears()
    {
        Rblyear.Items.Clear();
        LearnSite.BLL.Works wbll = new LearnSite.BLL.Works();
        Rblyear.DataSource     = wbll.ShowWyears();
        Rblyear.DataTextField  = "Wyear";
        Rblyear.DataValueField = "Wyear";
        Rblyear.DataBind();
        int icount = Rblyear.Items.Count;

        if (icount > 0)
        {
            Rblyear.SelectedIndex = icount - 1;
        }
    }