add item to listbox c# code example
Example: add items to listbox from text file c#
ListBox lb = new ListBox();
System.IO.StreamReader sr = new System.IO.StreamReader("userTypes.txt");
while (!sr.EndOfStream)
{
lb.Items.Add(sr.ReadLine());
}
sr.Close();