void BindCityAndArea() { Doctors o = new Doctors(); DataSet ds = o.GetCitiesAndAreas(); DataView dvCities = new DataView(ds.Tables[0]); DataView dvAreas = new DataView(ds.Tables[0]); //dvCities.RowFilter = " Distinct City"; CityList.DataSource = dvCities.ToTable(); CityList.DataTextField = "City"; CityList.DataValueField = "City"; CityList.DataBind(); CityList.Items.Insert(0, "Select"); AreaList.DataSource = ds; AreaList.DataTextField = "LocationName"; AreaList.DataValueField = "LocationId"; AreaList.DataBind(); AreaList.Items.Insert(0, "Select"); HospitalCityList.DataSource = dvCities.ToTable(); HospitalCityList.DataTextField = "City"; HospitalCityList.DataValueField = "City"; HospitalCityList.DataBind(); HospitalCityList.Items.Insert(0, "Select"); HospitalAreaList.DataSource = ds; HospitalAreaList.DataTextField = "LocationName"; HospitalAreaList.DataValueField = "LocationId"; HospitalAreaList.DataBind(); HospitalAreaList.Items.Insert(0, "Select"); HospitalList.Items.Insert(0, "Select"); LabCityList.DataSource = dvCities.ToTable(); LabCityList.DataTextField = "City"; LabCityList.DataValueField = "City"; LabCityList.DataBind(); LabCityList.Items.Insert(0, "Select"); LabAreaList.DataSource = ds; LabAreaList.DataTextField = "LocationName"; LabAreaList.DataValueField = "LocationId"; LabAreaList.DataBind(); LabAreaList.Items.Insert(0, "Select"); }