Reputation:
I have a ListBox defined in my app that I've populated with some static data in the XAML code. If I were to reference this ListBox in my C# code, e.g.
searchList.....;
What method does one use to then dynamically add items to that ListBox in your code?
Thanks in advance!
Upvotes: 2
Views: 6534
Reputation: 1637
Check out the listBox.Add.
Example:
listBox1.Items.Add("Your item");
Hope it helps
Upvotes: 5