Пример #1
0
    public void InitFenZhan()
    {
        FenZhanBLL bll = new FenZhanBLL();
        DataTable  dt  = bll.GetFenZhanList();

        if (dt != null && dt.Rows.Count > 0)
        {
            FenZhanList.DataSource     = dt;
            FenZhanList.DataValueField = "ProvinceID";
            FenZhanList.DataTextField  = "FenZhanName";
            FenZhanList.DataBind();
        }

        ListItem item = new ListItem();

        item.Value = "0";
        item.Text  = "所有分站";
        FenZhanList.Items.Insert(0, item);
    }
Пример #2
0
 public void BindData()
 {
     FenZhanList.DataSource = bll.GetFenZhanList();
     FenZhanList.DataBind();
 }