private void LoadDDLs() { Cities objCities = new Cities(); objCities.LoadAll(); uiDropDownListCity.DataSource = objCities.DefaultView; uiDropDownListCity.DataTextField = "ArName"; uiDropDownListCity.DataValueField = "CityID"; uiDropDownListCity.DataBind(); Categories objCats = new Categories(); objCats.LoadAll(); uiDropDownListCategory.DataSource = objCats.DefaultView; uiDropDownListCategory.DataTextField = "ArName"; uiDropDownListCategory.DataValueField = "CategoryID"; uiDropDownListCategory.DataBind(); SubCategories objSubCat = new SubCategories(); objSubCat.LoadAll(); uiDropDownListSubCategory.DataSource = objSubCat.DefaultView; uiDropDownListSubCategory.DataTextField = "ArName"; uiDropDownListSubCategory.DataValueField = "SubCategoryID"; uiDropDownListSubCategory.DataBind(); Packages objPackages = new Packages(); objPackages.LoadAll(); uiDropDownListPackages.DataSource = objPackages.DefaultView; uiDropDownListPackages.DataTextField = "EnName"; uiDropDownListPackages.DataValueField = "PackageID"; uiDropDownListPackages.DataBind(); uiDropDownListCategoryFilter.DataSource = objCats.DefaultView; uiDropDownListCategoryFilter.DataTextField = "ArName"; uiDropDownListCategoryFilter.DataValueField = "CategoryID"; uiDropDownListCategoryFilter.DataBind(); uiDropDownListCategoryFilter.Items.Insert(0, new ListItem("Select Category", "0")); }
private void LoadDDLs() { Cities objCities = new Cities(); objCities.LoadAll(); uiDropDownListCity.DataSource = objCities.DefaultView; uiDropDownListCity.DataTextField = "ArName"; uiDropDownListCity.DataValueField = "CityID"; uiDropDownListCity.DataBind(); uiDropDownListCity.Items.Insert(0, new ListItem("إختر المدينة", "0")); Categories objCategories = new Categories(); objCategories.LoadAll(); uiDropDownListCategory.DataSource = objCategories.DefaultView; uiDropDownListCategory.DataTextField = "ArName"; uiDropDownListCategory.DataValueField = "CategoryID"; uiDropDownListCategory.DataBind(); uiDropDownListCategory.Items.Insert(0, new ListItem("إختر قطاع العمل", "0")); Packages objpack = new Packages(); objpack.LoadAll(); uiDropDownListPackage.DataSource = objpack.DefaultView; uiDropDownListPackage.DataTextField = "EnName"; uiDropDownListPackage.DataValueField = "PackageID"; uiDropDownListPackage.DataBind(); }
private void BindData() { BLL.Packages objData = new Packages(); objData.LoadAll(); uiGridViewPackages.DataSource = objData.DefaultView; uiGridViewPackages.DataBind(); }