public static List <vGetProductSubCagetoryList> PMprint_ProductSubCategory(long ProductSubCategoryID) { CustomProfile profile = CustomProfile.GetProfile(); BrilliantWMS.ProductSubCategoryService.iProductSubCategoryMasterClient productsubcategoryClient = new BrilliantWMS.ProductSubCategoryService.iProductSubCategoryMasterClient(); List <vGetProductSubCagetoryList> SubCategoryList = new List <vGetProductSubCagetoryList>(); SubCategoryList = productsubcategoryClient.GetProductSubCategoryByProductCategoryID(ProductSubCategoryID, profile.DBConnection._constr).ToList(); return(SubCategoryList); }
protected void BindProductSubCategory() { ddlSubCategory.Items.Clear(); if (ddlCategory.SelectedIndex > 0) { CustomProfile profile = CustomProfile.GetProfile(); BrilliantWMS.ProductSubCategoryService.iProductSubCategoryMasterClient productsubcategoryClient = new BrilliantWMS.ProductSubCategoryService.iProductSubCategoryMasterClient(); //ProductSubCategoryService.connectiondetails conn = new ProductSubCategoryService.connectiondetails() { DataBaseName = Profile.DataBase, DataSource = Profile.DataSource, DBPassword = Profile.DBPassword }; ddlSubCategory.DataSource = productsubcategoryClient.GetProductSubCategoryByProductCategoryID(Convert.ToInt32(ddlCategory.SelectedItem.Value), profile.DBConnection._constr); ddlSubCategory.DataBind(); productsubcategoryClient.Close(); } if (ddlSubCategory.Items.Count > 0) { if (ddlSubCategory.Items[0].Text != "Not available") { ListItem lst = new ListItem(); lst.Text = "-Select-"; lst.Value = "0"; ddlSubCategory.Items.Insert(0, lst); } } }