public CascadingDropDownNameValue[] GetCountryData(string knownCategoryValues, string category)
{
Thread.Sleep(500);
List
StringDictionary sd = CascadingDropDown.ParseKnownCategoryValuesString(knownCategoryValues);
int RegionId = Convert.ToInt32(sd["undefined"]);
CountryByRegionIdTableAdapter cbrta = new CountryByRegionIdTableAdapter();
CountryDataSet.CountryByRegionIdDataTable cbrdt = cbrta.GetCountryByRegionId(RegionId, SessionManager.CaseStudyUserID);
foreach (DataRow dr in cbrdt.Rows)
{
Countries.Add(new CascadingDropDownNameValue(Convert.ToString(dr["CountryName"]), Convert.ToString(dr["CountryID"])));
}
return Countries.ToArray();
}
No comments:
Post a Comment