private void PopulateDropDownForFirstCategory() { List <Category> objCategoryList = new List <Category>(); objCategoryBiz = new CategoryBiz(); objCategoryList = objCategoryBiz.GetCategoryList(); ddlFirstCategory.DataSource = objCategoryList; ddlFirstCategory.DataValueField = "CategoryId"; ddlFirstCategory.DataTextField = "CategoryName"; ddlFirstCategory.DataBind(); }
private void PopulateDropDownForFirstCategory() { List <Category> objCategoryList = new List <Category>(); objCategoryBiz = new CategoryBiz(); objCategoryList = objCategoryBiz.GetCategoryList(); ddlFirstCategory.DataSource = objCategoryList; ddlFirstCategory.DataValueField = "CategoryId"; ddlFirstCategory.DataTextField = "CategoryName"; ddlFirstCategory.DataBind(); ddlFirstCategory.Items.Insert(0, new ListItem("--Select Category--", "0")); }
private void PopulateDropDownForThirdCategory() { objCategory = new Category(); List <Category> objCategoryList = new List <Category>(); objCategoryBiz = new CategoryBiz(); objCategory.CategoryParentId = Convert.ToInt16(ddlSecondCategory.SelectedValue); objCategoryList = objCategoryBiz.GetCategoryList(objCategory); ddlThirdCategory.DataSource = objCategoryList; ddlThirdCategory.DataValueField = "CategoryId"; ddlThirdCategory.DataTextField = "CategoryName"; ddlThirdCategory.DataBind(); }
private void PopulateDropDownForSecondCategory() { objCategory = new Category(); List <Category> objCategoryList = new List <Category>(); objCategoryBiz = new CategoryBiz(); objCategory.CategoryParentId = Convert.ToInt16(ddlFirstCategory.SelectedValue); objCategoryList = objCategoryBiz.GetCategoryList(objCategory); ddlSecondCategory.DataSource = objCategoryList; ddlSecondCategory.DataValueField = "CategoryId"; ddlSecondCategory.DataTextField = "CategoryName"; ddlSecondCategory.DataBind(); ddlSecondCategory.Items.Insert(0, new ListItem("--Select Category--", "0")); }