Can I somehow use POCOs in a ListView? Or are ListViewItem’s my only option?
If I can only use ListViewItems is it possible to assign a value object (my POCO) or is it possible to use subitems with value objects?
Thanks in advance!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can use ObjectListView which plays very nicely with POCOs.
Update
ObjectListView is based on the regular ListView, but it uses some magic and the win32 api to make everything possible. It’s not very hard to get started with it and I don’t really see why you can’t use it?
Standard listview: All options (except owner drawing) include using a ListViewItem. If you got a large collection I recommend that you use Virtual Mode which means that the list view will request each item that is visible.