If I have a list of strings, eg:
List<string> MyList = new List<string>(); MyList.Add("HELLO"); MyList.Add("WORLD");
Is there an easy way to populate a ListBox using the contents of MyList?
Try :
List<string> MyList = new List<string>(); MyList.Add("HELLO"); MyList.Add("WORLD"); listBox1.DataSource = MyList;
Have a look at ListControl.DataSource Property
1.4m articles
1.4m replys
5 comments
57.0k users