Forums - C# Corner

Forum guidelines
Sandeep Kumar

Sandeep Kumar

  • 412
  • 4.3k
  • 515.1k

Comma seperated data in Dropdownlist

Jun 26 2018 7:51 AM
Hi Guys,
I have one dropdown and I need to display  data in  dropdown as comma seprated like a,b,c
Here is my code:
rddlMuster.DataTextField = "ZoneName";
rddlMuster.DataValueField = "ZoneID";
rddlMuster.DataSource = objUtilsDAO.GetZonesByYardID(lstYards.FirstOrDefault().YardID).Where(zm => zm.IsCS == false && zm.ZoneType == (int)Enums.ZoneType.Mustering_Zone).OrderBy(zm => zm.ZoneName);
Can anyone please help me to get comma seprated value in dropdown while  working with linq in 

Answers (5)