I have numerous groupboxes that need to be listed in a ListView.
I have tried:
listView1.Controls.Add(new NewsBox());
(NewsBox bei开发者_如何学JAVAng a custom class derived from GroupBox, just with standard labels and a definite size)
Anyways, that works for listing the first controlbox, but not for 2 or more.
Any ideas?
This won't work. You can't have multiple GroupBoxes in a ListView control.
To add things to a ListView, use myListView.Items.Add(...).
精彩评论