Exemplo n.º 1
0
        public static void fillCheckBoxListCity(CheckBoxList chkl)
        {
            CityBAL balCity = new CityBAL();

            chkl.DataSource     = balCity.SelectForDropDownList();
            chkl.DataValueField = "CityID";
            chkl.DataTextField  = "CityName";
            chkl.DataBind();
        }
Exemplo n.º 2
0
        public static void fillDropDownListCity(DropDownList ddl)
        {
            CityBAL balCity = new CityBAL();

            ddl.DataSource     = balCity.SelectForDropDownList();
            ddl.DataValueField = "CityID";
            ddl.DataTextField  = "CityName";
            ddl.DataBind();
            ddl.Items.Insert(0, new ListItem("Select City", "-1"));
        }