Basically I have a Listview control which has coloums (displayed in Detail mode) I add items to it that I want displayed, each under 1 colomn (Like an invoice) but it displays them all under the first instead. I've been adding items like this below which I guess is the wrong way to do it but every other way I tried is not working. You can see he result in the screenshot.
lstVLine.Items.Add(lineItem, lstVLine.Items.Count);
lstVLine.Items.Add(itemName,lstVLi开发者_运维知识库ne.Items.Count);
You need to create SubItems for each of the additional fields:
ListViewItem item = new ListViewItem ("Something");
item.SubItems.Add ("Brand info");
item.SubItems.Add ("Type info");
lstVLine.Items.Add(item);
精彩评论