示例#1
0
        protected void ddlRegion_SelectedIndexChanged(object sender, EventArgs e)
        {
            Place  pl  = new Place();
            string reg = ddlRegion.SelectedItem.Value;

            regionList = pl.SelectByRegion(reg);
            DatalistRegion.DataSource = regionList;
            DatalistRegion.DataBind();
        }
示例#2
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (IsPostBack == false)
            {
                Place pl = new Place();
                ratingList = pl.GetTop3Rating();

                DatalistRating.DataSource = ratingList;
                DatalistRating.DataBind();

                string reg = ddlRegion.SelectedItem.Value;
                regionList = pl.SelectByRegion(reg);
                DatalistRegion.DataSource = regionList;
                DatalistRegion.DataBind();
            }
        }