c# add object to listbox and show string of object in it

I'm using a ListBox and adding objects to it.

The object contains 2 variables, let's say username and userid.

How can I add the objects in the list (like listbox.Items.Add(object);) and show the username of that object?

Thnx!

23
задан R.J. Dunnill 21 November 2019 в 22:17
поделиться